Jump integrates with your shell and learns about your navigational habits bykeeping track of the directories you visit. It gives you the most visiteddirectory for the shortest search term you type.
Jump comes in packages for the following platforms.
Platform | Command |
---|---|
macOS | brew install jump |
Ubuntu | wget https://github.com/gsamokovarov/jump/releases/download/v0.40.0/jump_0.40.0_amd64.deb && sudo dpkg -i jump_0.40.0_amd64.deb |
Fedora | wget https://github.com/gsamokovarov/jump/releases/download/v0.40.0/jump-0.40.0-1.x86_64.rpm && sudo rpm -i jump-0.40.0-1.x86_64.rpm |
Void | xbps-install -S jump |
Nix | nix-env -iA nixpkgs.jump |
Go | go get github.com/gsamokovarov/jump |
Jump needs to be integrated with the shell. For bash
and zsh
, the linebelow needs to be in ~/.bashrc
, ~/bash_profile
or ~/.zshrc
:
eval "$(jump shell)"
For fish shell, put the line below needs to be in ~/.config/fish/config.fish
:
status --is-interactive; and source (jump shell fish | psub)
Once integrated, jump will automatically monitor directory changes and startbuilding an internal database.
j
is not my favourite letter!This is fine, you can bind jump to z
, with this:
eval "$(jump shell --bind=z)"
And now, you can use jump
like z dir
and it would just work! This is onlyan example, you can bind it to anything. If you are one of those persons thatlikes to type a lot with their fingers, you can do:
eval "$(jump shell --bind=goto)"
Voila! goto dir
becomes a thing. The possibilities are endless!
Once integrated, jump introduces the j helper. It accepts only searchterms and as a design goal there are no arguments to j. Whatever you giveit, it's treated as search term.
Jump uses fuzzy matching to find the desired directory to jump to. Thismeans that your search terms are patterns that match the desired directoryapproximately rather than exactly. Typing 2 to 5 consecutive charactersof the directory name is all that jump needs to find it.
The default search behavior of jump is to fuzzy match thedirectory name of a score. The match is case insensitive.
If you visit the directory /Users/genadi/Development/rails/web-console
often,you can jump to it by:
$ j wc # or...
$ j webc # or...
$ j console # or...
$ j b-c # or...
Using jump is all about saving key strokes. However, if you made the effort totype a directory base name exactly, jump will try to find the exact match,rather than fuzzy search.
$ j web-console
$ pwd
/Users/genadi/Development/rails/web-console
Given the following directories:
/Users/genadi/Development/society/website
/Users/genadi/Development/chaos/website
Typing j site
matches only the base names of the directories. The base nameof /Users/genadi/Development/society/website
is website
, the same as theother absolute path above. The jump above will land on the most scrored path,which is the society
one, however what if we wanted to land on the chaos
website?
$ j ch site
$ pwd
/Users/genadi/Development/chaos/website
This instructs jump to look for a site
match inside that is preceded by ach
match in the parent directory. The search is normalized only on the lasttwo parts of the target paths. This will ensure a better match, because of theshorter path to fuzzy match on.
There are no depth limitations though and a jump to/Users/genadi/Development/society/website
can look like:
$ j dev soc web
$ pwd
/Users/genadi/Development/society/website
In fact, every space passed to j
is converted to an OS separator. The lastsearch term can be expressed as:
$ j dev/soc/web
$ pwd
/Users/genadi/Development/society/website
Bad jumps happen. Sometimes we're looking for a directory that doesn't have thebest score at the moment. Let's work with the following following jump database:
/Users/genadi/Development/society/website
/Users/genadi/Development/chaos/website
/Users/genadi/Development/hack/website
Typing j web
would lead to:
$ j web
$ pwd
/Users/genadi/Development/society/website
If we didn't expect this result, instead of another search term, typing jwithout any arguments will instruct jump to go the second best match.
$ j
$ pwd
/Users/genadi/Development/chaos/website
To trigger a case-sensitive search, use a term that has a capital letter.
$ j Dev
$ pwd
/Users/genadi/Development
The jump will resolve to /Users/genadi/Development
even if there is/Users/genadi/Development/dev-tools
that scores better.
Yes, it is! You can import your datafile from autojump
or z
with:
$ jump import
This will try z
first then autojump
, so you can even combine all theentries from both tools.
The command is safe to run on pre-existing jump database, because if an entryexist in jump already, it won't be imported and it's score will remainunchanged. You can be explicit and choose to import autojump
or z
with:
$ jump import autojump
$ jump import z
If you want to know more about the difference between Jump, z, and autojump,check-out this Twitter conversation.
Thank you for stopping by and showing your interest in Jump!
上一篇:简单的cpu指令—(计算机基础课十九) 现在用 JUMP 让程序更有趣一些。 我们还把内存中 3 和 14 两个数字,改成 1 和 1,现在来从 CPU 的视角走一遍程序。 首先 LOAD_A 14,把 1 存入寄存器A(因为地址 14 里的值是 1)。 然后 LOAD_B 15,把 1 存入寄存器B\N(因为地址 15 里的值也是 1)。 然后 ADD B A 把寄存器 B 和 A
1. 前言 限于作者能力水平,本文可能存在谬误,因此而给读者带来的损失,作者不做任何承诺。 2. 背景 本文基于 Linux 4.14 内核源码,以及 ARM32架构 进行分析。 3. Jump label 实现 3.1 为什么引入 Jump label? 在内核代码中,有很多分支判断条件,它们在绝大多数情形下,都是不成立的,类似如下代码: if (unlikely(condition)) { /
1.1 题目 Given an array of non-negative integers, you are initially positioned at the first index of the array. Each element in the array represents your maximum jump length at that position. Determine
Question lintcode: (117) Jump Game II Given an array of non-negative integers, you are initially positioned at the first index of the array. Each element in the array represents your maximum jump len
Question lintcode: (116) Jump Game Given an array of non-negative integers, you are initially positioned at the first index of the array. Each element in the array represents your maximum jump length
在这个问题中,一些答案表明,不使用“if”语句就可以做出决策,但我怀疑这是可能的,因为“if”不是生成跳转指令的唯一语句。 给定一种固定的编译语言(在示例C中),生成的程序集是否可以在不使用跳转和转到指令的情况下执行某种决策? 请给出一个简单的if/else语句的替代示例,在肯定回答的情况下,该语句不使用此类说明。
本文向大家介绍CALL和JUMP指令之间的区别,包括了CALL和JUMP指令之间的区别的使用技巧和注意事项,需要的朋友参考一下 在本节中,我们将看到CALL和JUMP指令之间的区别是什么。CALL指令用于调用子例程,但是JUMP指令更新程序计数器值并指向程序内部的另一个位置。 现在让我们看一下CALL和JUMP指令之间的一些详细区别。 跳指令 通话指令 通过使用JUMP,程序控制转移到一个位置,该
我正试图在Rocket.Chat上使用JumpCloud.com获得LDAP 我从我搜索的用户那里得到一个结果,电子邮件等等。从JumpCloud.com来看,一切都在正常工作 我遇到的麻烦是让Rocket.Chat与JumpCloud.com一起工作 绑定搜索:使用了我能找到的所有配置(见下文) 可分辨名称(DN):DC=JumpCloud,DC=com 启用LDAP:True LDAP URL
Given an array of non-negative integers, you are initially positioned at the first index of the array. Each element in the array represents your maximum jump length at that position. Determine if you
type 字符串 (可选)-以下之一: task-任务将启动具有特定参数的应用程序。 separator-可用于分隔标准 Tasks 类别中的项目。 file-一个文件的链接将使用创建跳转列表的应用程序打开文件, 为此, 应用程序必须注册为该文件类型的默认程序 (尽管它并不需要成为默认程序)。 pathString (可选)-要打开的文件的路径, 只应在 type 为 file 时设置。 prog