slai11 / goto Goto Github PK
View Code? Open in Web Editor NEWgt your desired path with minimal keystrokes
Home Page: https://crates.io/crates/goto-rs
License: MIT License
gt your desired path with minimal keystrokes
Home Page: https://crates.io/crates/goto-rs
License: MIT License
These warnings could probably be fixed using the dirs crate. I use dirs for one of my projects at https://github.com/theimpossibleastronaut/oxi-rmw/blob/b1c90d8450e74fbec4a56a8f732d73075574ad3c/src/main.rs#L8
andy@oceanus:~/src/rust/goto$ cargo clippy
warning: use of deprecated item 'std::env::home_dir': This function's behavior is unexpected and probably not what you want. Consider using a crate from crates.io instead.
--> src/db.rs:17:11
|
17 | match env::home_dir().map(|p| format!("{}/{}", p.display(), ".config/goto")) {
| ^^^^^^^^^^^^^
|
= note: `#[warn(deprecated)]` on by default
warning: use of deprecated item 'std::env::home_dir': This function's behavior is unexpected and probably not what you want. Consider using a crate from crates.io instead.
--> src/db.rs:41:11
|
41 | match env::home_dir().map(|p| format!("{}/{}", p.display(), ".config/goto/db.txt")) {
| ^^^^^^^^^^^^^
It would be nice to pretty-print the index in a manner similar to how tree
does their output of directory.
When --version
or -V
is used, only gt
is output.
I'm going to submit a PR to fix that.
I'm exploring a new mode of using gt
that does not involve typing the shorthand for the destination.
> gg
======= Current Indexed Directories (alias highlighted) =======
└─ Users
└─ sylvester
├─ Documents
│ └─ pages [1]
├─ go
│ └─ src
│ ├─ apiproxy [2]
│ ├─ bistromath-api [3]
│ ├─ device-db [4]
│ └─ playback-streams [5]
└─ gitlab
└─ gdk [6]
Select jump target: _
Instead of typing gt glb
, we now expose the option to type gg
(or any other new alias) + number
. This could be useful when working with folders of very similar namespace.
The only concern I have is that this ls
tree could get really big. Perhaps beyond a certain size (20?), we should just keep the most-recently-used paths.
This could be broken down into a couple of actionables
gg
)-a/--all
mode to show all. OR incorporate it with ls
.This feature seems like a natural requirement, a gt rm
of sorts.
Adding patha/special_name
after pathb/special_name
will override the first instance.
special_name,/pathb/special_name
becomes
special_name,/patha/special_name
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.