simmons / tupm Goto Github PK
View Code? Open in Web Editor NEWTerminal Universal Password Manager
License: MIT License
Terminal Universal Password Manager
License: MIT License
Hi David,
I have started studying the code and I ran into seemingly arbitrary choices between static
and const
. According to the docs, the only difference is inlining for const and the fact that only fields defined static
have a fixed memory address (maybe relevant if directly using the memory address).
My question is: did you at the time of writing consider this difference? Or did you have some other reason for making some fields static and some const?
Quick question. Since I did a rustup update (for Cursive actually) and a cargo update, I have a different lockfile where many the dependencies were updated to a slightly higher version (3rd number in the version). git diff
shows it is different. For instance the crate serde went from 1.0.88 to 1.0.89. And many others with it.
I was wondering what the implication is and whether I should change something in order to get the original Cargo.lock.
Yes, I know, a newbie question.
From discussion with @gbonnema in #2 and #3, I've learned that newer builds of tupm are resulting in garbage characters being displayed on the terminal:
I've tracked this down to an issue in the ncurses crate: jeaye/ncurses-rs/issues/180
There was a memory corruption issue in unsafe Rust code that was wrapping the ncurses setlocale()
function. I've submitted a PR to fix the bug: jeaye/ncurses-rs#181
When this issue is resolved in the ncurses crate and a new version published, we'll need to make sure tupm and Cursive is using this newer version.
Hello,
I forked your repo for tupm and for cargo build I got among others
the following message:
"This crate is only compatible with OpenSSL 1.0.1, 1.0.2, and 1.1.0, or LibreSSL
2.5 and 2.6.0, but a different version of OpenSSL was found. The build is now
aborting due to this version mismatch."
If I run this with OpenSSL 1.0.1/1.0.2 or 1.1.0 could I expect things to behave differently?
P.S. I am starting to grasp Rust, but I am still a long way from home, so I hope you forgive my ignorance if I could just insert a newer version of openssl. Because of the encryption involved I err on the side of caution.
I also uploaded the compile output:
klad.txt
While using your mvc setup to create my own application, I came across "flatpack" which you use for the database. I did some searching, and came with a lot of "flatpak" (not the same). and I noticed that you created all flatpack io in your own routines, not using a crate. So ..... I was wondering whether the flatpack
you use is something specific to upm
or a more general storage method?
Maybe for a new app, I shouldn't be using flatpak
?
Kind regards, Guus.
See #3 (PR for new versions in tupm).
I tested some more, and, when using the testdatabase everything seems to work. What I did not test yet is synchronization. I wil get to that later.
For now, I have a question. The screen is divided into 2 boxes. The left one contains a list of the accounts present. The right one is empty. When I press enter on one of the accounts, I get a dialog where I can view and change stuff.
The question is now: is the main part of the screen (the box on the right) that seems empty to me, supposed to be empty? Or should something be there, and I am just not seeing it because my changes messed something up?
Kind regards, Guus.
Hi David,
I found in the docs that the expression &some(ref after)
is no longer necessary because the compiler takes care of it, and it reads easier. Also, I didn't create a PR because my repo appears to be just a little out of sync with your repo. Not sure what to do about it, unless I delete the fork. Below the change I would have requested. Hopefullly the line numbers are not off.
diff --git a/src/bin/tupm/controller.rs b/src/bin/tupm/controller.rs
index 6034e1c..15c937f 100644
--- a/src/bin/tupm/controller.rs
+++ b/src/bin/tupm/controller.rs
@@ -195,7 +195,7 @@ impl Controller {
fn handle_account_edit(&mut self, before: Option<Account>, after: Option<Account>) {
let mut modified = false;
- if let (&Some(ref before), &Some(ref after)) = (&before, &after) {
+ if let (Some(before), Some(after)) = (&before, &after) {
// Update account
if before != after {
if let Err(e) = self.database.update_account(&before.name, &after) {
@@ -204,14 +204,14 @@ impl Controller {
}
modified = true;
}
- } else if let (&None, &Some(ref account)) = (&before, &after) {
+ } else if let (None, Some(account)) = (&before, &after) {
// Create account
if let Err(e) = self.database.add_account(account) {
self.ui.set_statusline(&format!("Error: {}", e));
return;
}
modified = true;
- } else if let (&Some(ref account), &None) = (&before, &after) {
+ } else if let (Some(account), None) = (&before, &after) {
// Delete account
self.database.delete_account(account.name.as_str());
modified = true;
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.