Autojump: Homebrewでインストールした後、macOSでこれを機能させるために何を調達しますか?

作成日 2017年11月27日  ·  13コメント  ·  ソース: wting/autojump

動作させることができません。

常にこのメッセージを受け取ります:

Please source the correct autojump file in your shell's
startup file. For more information, please reinstall autojump
and read the post installation instructions.

助けてくれてありがとう。

最も参考になるコメント

コマンドを使用して警告を再度確認できます

brew info autojump

そしてそれはあなたに出力を与えるでしょう

autojump: stable 22.5.1 (bottled), HEAD
Shell extension to jump to frequently used directories
https://github.com/wting/autojump
/usr/local/Cellar/autojump/22.5.1 (24 files, 253.9KB) *
  Poured from bottle on 2017-11-28 at 13:37:16
From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/autojump.rb
==> Caveats
Add the following line to your ~/.bash_profile or ~/.zshrc file (and remember
to source the file to update your current session):
  [ -f /usr/local/etc/profile.d/autojump.sh ] && . /usr/local/etc/profile.d/autojump.sh

If you use the Fish shell then add the following line to your ~/.config/fish/config.fish:
  [ -f /usr/local/share/autojump/autojump.fish ]; and source /usr/local/share/autojump/autojump.fish

zsh completions have been installed to:
  /usr/local/share/zsh/site-functions

全てのコメント13件

「インストール後の手順を読んでください」と書かれている部分を試しましたか?

https://github.com/wting/autojump#installation

私は持っている。 macOSの場合、 brew installとだけ表示され、それだけです。

brew installは、インストール後の手順を示します。 そこにあるのには理由があります。

https://github.com/Homebrew/homebrew-core/blob/b6b9f36c8744c2259b74f12850163c676ae49396/Formula/autojump.rb#L27 -L35

コマンドを使用して警告を再度確認できます

brew info autojump

そしてそれはあなたに出力を与えるでしょう

autojump: stable 22.5.1 (bottled), HEAD
Shell extension to jump to frequently used directories
https://github.com/wting/autojump
/usr/local/Cellar/autojump/22.5.1 (24 files, 253.9KB) *
  Poured from bottle on 2017-11-28 at 13:37:16
From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/autojump.rb
==> Caveats
Add the following line to your ~/.bash_profile or ~/.zshrc file (and remember
to source the file to update your current session):
  [ -f /usr/local/etc/profile.d/autojump.sh ] && . /usr/local/etc/profile.d/autojump.sh

If you use the Fish shell then add the following line to your ~/.config/fish/config.fish:
  [ -f /usr/local/share/autojump/autojump.fish ]; and source /usr/local/share/autojump/autojump.fish

zsh completions have been installed to:
  /usr/local/share/zsh/site-functions

[ -f /usr/local/etc/profile.d/autojump.sh ] && . /usr/local/etc/profile.d/autojump.sh追加してファイルを調達した後でも、まだ機能しません。

j <dirname>と、dirsを変更する代わりに、現在のディレクトリに残ります。

次回j <dirname>電話したときに、autojumpがそれを記憶するよりも、最初にcd <dirname>する必要があります。

ああ、落とし穴、私は目的を誤解したので、自動ジャンプは、現在の場所から深くネストされたサブディレクトリを見つけるのではなく、あなたがどこにいたかを覚えて、すぐにそこに戻ることができるようにすることです。

はい、README.mdから引用されています

これは、コマンドラインから最もよく使用するディレクトリのデータベースを維持することによって機能します。

_ディレクトリにジャンプする前に、最初にディレクトリにアクセスする必要があります。_

私もこの問題に直面しています。
Homebrewを介してインストールした後、これを.bash_profileに追加しました。
[ -f /usr/local/etc/profile.d/autojump.sh ] && . /usr/local/etc/profile.d/autojump.sh
また、次のことも追加しました。
export PROMPT_COMMAND="${PROMPT_COMMAND:+$PROMPT_COMMAND ;} history -a"

いくつかのディレクトリにcdした後、 j -sにはエントリがありません。 現在のセッションで.bash_profile行を手動で実行する必要があります。 これはどういうわけか私の.bash_profileの設定の問題ですか?

@ helenes-r7と同じ問題があります

Homebrewを介してインストールした後、これを.bash_profileに追加しました。
[ -f /usr/local/etc/profile.d/autojump.sh ] && . /usr/local/etc/profile.d/autojump.sh

いくつかのディレクトリにcdした後、j-sにはエントリがありません。

はい、セッションをリロードするためにsource ~/.bash_profileを実行しました

@ helenes-r7 @ l-gothbergここで質問について読むことができますhttps://apple.stackexchange.com/questions/12993/why-doesnt-bashrc-run-automatically

チャイムをしてくれた@apheに感謝します。

Autojumpは、すべてのユーザーが異なるシェルと潜在的にカスタマイズされたセットアップを使用しているため、インストール後のセットアップが必要であるという意味でユニークです。一部のパッケージディストリビューションでは、インストール後の構成が許可されていません(Debianなど)。

#323のインストール後の手順を改善する予定なので、フィードバックをそこにリダイレクトしてください。

これがreadmeに含まれていると便利です。

[ -f /usr/local/etc/profile.d/autojump.sh ] && . /usr/local/etc/profile.d/autojump.sh

インストール後の手順を読んでいませんでした(申し訳ありません!)。箱から出してすぐに機能すると思いました。
たぶん、これは「インストール後の手順を読む」の横/代わりに追加することもできます

このページは役に立ちましたか?
0 / 5 - 0 評価

関連する問題

srid picture srid  ·  14コメント

rsparkyc picture rsparkyc  ·  11コメント

davux picture davux  ·  9コメント

qazip picture qazip  ·  3コメント

grota picture grota  ·  16コメント