cdhist 4.2__tar.gz → 4.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,10 +9,10 @@ check:
9
9
 
10
10
  build:
11
11
  rm -rf dist
12
- python3 -m build --sdist --wheel
12
+ uv build
13
13
 
14
14
  upload: build
15
- twine3 upload dist/*
15
+ uv-publish
16
16
 
17
17
  doc:
18
18
  update-readme-usage
@@ -1,9 +1,9 @@
1
- Metadata-Version: 2.2
1
+ Metadata-Version: 2.4
2
2
  Name: cdhist
3
- Version: 4.2
3
+ Version: 4.4
4
4
  Summary: Program to provide a Linux cd history directory stack
5
5
  Author-email: Mark Blakeney <mark.blakeney@bullet-systems.net>
6
- License: GPLv3
6
+ License-Expression: GPL-3.0-or-later
7
7
  Project-URL: Homepage, https://github.com/bulletmark/cdhist
8
8
  Keywords: bash,zsh,cd,fzf,git,worktree
9
9
  Classifier: Programming Language :: Python :: 3
@@ -85,14 +85,19 @@ Change immediately to directory corresponding to stack index 4:
85
85
  $ cd -4
86
86
  ```
87
87
 
88
- Search back through stack for directory containing "string" and `cd`
89
- there:
88
+ Note that `cd -1` is equivalent to the native `cd -` for the previous
89
+ directory, `cd -2` is the directory before that, etc.
90
+
91
+ Search back through stack for directory containing "string" in it's name and
92
+ `cd` there:
90
93
 
91
94
  ```sh
92
95
  $ cd -/string
93
96
  ```
94
97
 
95
- Note, you can also type `string` at the `cd --` prompt to search.
98
+ Note, you can also type the text `string` at the `cd --` prompt to search, although for
99
+ frequent searching it is probably better to use an [integrated fuzzy
100
+ finder](#fuzzy-finder-integration).
96
101
 
97
102
  Show help/usage:
98
103
 
@@ -192,16 +197,23 @@ E.g. to use [`fzf`][fzf]:
192
197
  source <(cdhist -i "cd -F fzf")
193
198
  ```
194
199
 
195
- Or, to use [`television`][television]:
200
+ Or, to use [`television`][television] with [`exa`][exa] to show a preview of
201
+ directory contents:
196
202
 
197
203
  ```sh
198
- source <(cdhist -i "cd -F \"tv --no-preview\"")
204
+ source <(cdhist -i "cd -uF \"tv --preview 'exa --color=always -l@F=always {}'\"")
199
205
  ```
200
206
 
201
207
  Now when you type `cd --` you will be prompted with a list of directories via
202
208
  your fuzzy finder so you can search for a directory to select by fuzzy text
203
209
  matching.
204
210
 
211
+ Note if you use [`television`][television] then it is suggested to set the
212
+ `television` option `input_bar_position = bottom` in the `ui` section of your
213
+ [`~/.config/television/config.toml`](https://github.com/alexpasmantier/television/blob/main/.config/config.toml)
214
+ file so that the input bar is at the bottom of the screen and close where your
215
+ terminal prompt usually is.
216
+
205
217
  In the following description, [`fzf`][fzf] will be used as it is by far the
206
218
  most popular fuzzy finder and the one used by the author. When you set up `fzf`
207
219
  [shell integration](https://junegunn.github.io/fzf/shell-integration/) then you
@@ -218,7 +230,7 @@ I disable that function in `fzf` by setting the `FZF_ALT_C_COMMAND` to an empty
218
230
  string before I source `fzf` in my `.bashrc` when [setting `fzf` up](https://junegunn.github.io/fzf/shell-integration/#setting-up-shell-integration).
219
231
 
220
232
  Then I set the following shell key binding in my `~/.inputrc` file (need to
221
- restart your shell to activate):
233
+ restart your login shell/terminal to activate):
222
234
 
223
235
  ```sh
224
236
  "\ec": "cd --\n"
@@ -251,6 +263,11 @@ you don't then just specify the full path, e.g:
251
263
  source <(cdhist -i "cd -F /path-to/fzf")
252
264
  ```
253
265
 
266
+ ### Yazi Integration
267
+
268
+ [`cdhist.yazi`][cdhist.yazi] is a [Yazi][yazi] plugin that provides cdhist
269
+ functionality within the [Yazi][yazi] terminal file manager.
270
+
254
271
  ### GIT Worktree Integration
255
272
 
256
273
  [cdhist](http://github.com/bulletmark/cdhist) can be used to easily `cd`
@@ -415,3 +432,6 @@ Public License at <http://www.gnu.org/licenses/> for more details.
415
432
  [fzy]: https://github.com/jhawthorn/fzy
416
433
  [skim]: https://github.com/skim-rs/skim
417
434
  [television]: https://github.com/alexpasmantier/television
435
+ [cdhist.yazi]: https://github.com/bulletmark/cdhist.yazi
436
+ [yazi]: https://yazi-rs.github.io/
437
+ [exa]: https://github.com/ogham/exa
@@ -1,15 +1,3 @@
1
- Metadata-Version: 2.2
2
- Name: cdhist
3
- Version: 4.2
4
- Summary: Program to provide a Linux cd history directory stack
5
- Author-email: Mark Blakeney <mark.blakeney@bullet-systems.net>
6
- License: GPLv3
7
- Project-URL: Homepage, https://github.com/bulletmark/cdhist
8
- Keywords: bash,zsh,cd,fzf,git,worktree
9
- Classifier: Programming Language :: Python :: 3
10
- Requires-Python: >=3.8
11
- Description-Content-Type: text/markdown
12
-
13
1
  ## CDHIST - Linux Directory History
14
2
  [![PyPi](https://img.shields.io/pypi/v/cdhist)](https://pypi.org/project/cdhist/)
15
3
  [![AUR](https://img.shields.io/aur/version/cdhist)](https://aur.archlinux.org/packages/cdhist/)
@@ -85,14 +73,19 @@ Change immediately to directory corresponding to stack index 4:
85
73
  $ cd -4
86
74
  ```
87
75
 
88
- Search back through stack for directory containing "string" and `cd`
89
- there:
76
+ Note that `cd -1` is equivalent to the native `cd -` for the previous
77
+ directory, `cd -2` is the directory before that, etc.
78
+
79
+ Search back through stack for directory containing "string" in it's name and
80
+ `cd` there:
90
81
 
91
82
  ```sh
92
83
  $ cd -/string
93
84
  ```
94
85
 
95
- Note, you can also type `string` at the `cd --` prompt to search.
86
+ Note, you can also type the text `string` at the `cd --` prompt to search, although for
87
+ frequent searching it is probably better to use an [integrated fuzzy
88
+ finder](#fuzzy-finder-integration).
96
89
 
97
90
  Show help/usage:
98
91
 
@@ -192,16 +185,23 @@ E.g. to use [`fzf`][fzf]:
192
185
  source <(cdhist -i "cd -F fzf")
193
186
  ```
194
187
 
195
- Or, to use [`television`][television]:
188
+ Or, to use [`television`][television] with [`exa`][exa] to show a preview of
189
+ directory contents:
196
190
 
197
191
  ```sh
198
- source <(cdhist -i "cd -F \"tv --no-preview\"")
192
+ source <(cdhist -i "cd -uF \"tv --preview 'exa --color=always -l@F=always {}'\"")
199
193
  ```
200
194
 
201
195
  Now when you type `cd --` you will be prompted with a list of directories via
202
196
  your fuzzy finder so you can search for a directory to select by fuzzy text
203
197
  matching.
204
198
 
199
+ Note if you use [`television`][television] then it is suggested to set the
200
+ `television` option `input_bar_position = bottom` in the `ui` section of your
201
+ [`~/.config/television/config.toml`](https://github.com/alexpasmantier/television/blob/main/.config/config.toml)
202
+ file so that the input bar is at the bottom of the screen and close where your
203
+ terminal prompt usually is.
204
+
205
205
  In the following description, [`fzf`][fzf] will be used as it is by far the
206
206
  most popular fuzzy finder and the one used by the author. When you set up `fzf`
207
207
  [shell integration](https://junegunn.github.io/fzf/shell-integration/) then you
@@ -218,7 +218,7 @@ I disable that function in `fzf` by setting the `FZF_ALT_C_COMMAND` to an empty
218
218
  string before I source `fzf` in my `.bashrc` when [setting `fzf` up](https://junegunn.github.io/fzf/shell-integration/#setting-up-shell-integration).
219
219
 
220
220
  Then I set the following shell key binding in my `~/.inputrc` file (need to
221
- restart your shell to activate):
221
+ restart your login shell/terminal to activate):
222
222
 
223
223
  ```sh
224
224
  "\ec": "cd --\n"
@@ -251,6 +251,11 @@ you don't then just specify the full path, e.g:
251
251
  source <(cdhist -i "cd -F /path-to/fzf")
252
252
  ```
253
253
 
254
+ ### Yazi Integration
255
+
256
+ [`cdhist.yazi`][cdhist.yazi] is a [Yazi][yazi] plugin that provides cdhist
257
+ functionality within the [Yazi][yazi] terminal file manager.
258
+
254
259
  ### GIT Worktree Integration
255
260
 
256
261
  [cdhist](http://github.com/bulletmark/cdhist) can be used to easily `cd`
@@ -415,3 +420,6 @@ Public License at <http://www.gnu.org/licenses/> for more details.
415
420
  [fzy]: https://github.com/jhawthorn/fzy
416
421
  [skim]: https://github.com/skim-rs/skim
417
422
  [television]: https://github.com/alexpasmantier/television
423
+ [cdhist.yazi]: https://github.com/bulletmark/cdhist.yazi
424
+ [yazi]: https://yazi-rs.github.io/
425
+ [exa]: https://github.com/ogham/exa
@@ -7,6 +7,7 @@ import subprocess
7
7
  import sys
8
8
  from argparse import Namespace
9
9
  from pathlib import Path
10
+ import shlex
10
11
 
11
12
  HOME = Path.home()
12
13
 
@@ -23,7 +24,7 @@ def unexpanduser(path: str | Path) -> str:
23
24
 
24
25
  def fuzzy_prompt(args: Namespace, dirlist: list[str]) -> str | None:
25
26
  res = subprocess.run(
26
- args.fuzzy.split(), input='\n'.join(dirlist), stdout=subprocess.PIPE, text=True
27
+ shlex.split(args.fuzzy), input='\n'.join(dirlist), stdout=subprocess.PIPE, text=True
27
28
  )
28
29
 
29
30
  if res.returncode != 0:
@@ -1,3 +1,15 @@
1
+ Metadata-Version: 2.4
2
+ Name: cdhist
3
+ Version: 4.4
4
+ Summary: Program to provide a Linux cd history directory stack
5
+ Author-email: Mark Blakeney <mark.blakeney@bullet-systems.net>
6
+ License-Expression: GPL-3.0-or-later
7
+ Project-URL: Homepage, https://github.com/bulletmark/cdhist
8
+ Keywords: bash,zsh,cd,fzf,git,worktree
9
+ Classifier: Programming Language :: Python :: 3
10
+ Requires-Python: >=3.8
11
+ Description-Content-Type: text/markdown
12
+
1
13
  ## CDHIST - Linux Directory History
2
14
  [![PyPi](https://img.shields.io/pypi/v/cdhist)](https://pypi.org/project/cdhist/)
3
15
  [![AUR](https://img.shields.io/aur/version/cdhist)](https://aur.archlinux.org/packages/cdhist/)
@@ -73,14 +85,19 @@ Change immediately to directory corresponding to stack index 4:
73
85
  $ cd -4
74
86
  ```
75
87
 
76
- Search back through stack for directory containing "string" and `cd`
77
- there:
88
+ Note that `cd -1` is equivalent to the native `cd -` for the previous
89
+ directory, `cd -2` is the directory before that, etc.
90
+
91
+ Search back through stack for directory containing "string" in it's name and
92
+ `cd` there:
78
93
 
79
94
  ```sh
80
95
  $ cd -/string
81
96
  ```
82
97
 
83
- Note, you can also type `string` at the `cd --` prompt to search.
98
+ Note, you can also type the text `string` at the `cd --` prompt to search, although for
99
+ frequent searching it is probably better to use an [integrated fuzzy
100
+ finder](#fuzzy-finder-integration).
84
101
 
85
102
  Show help/usage:
86
103
 
@@ -180,16 +197,23 @@ E.g. to use [`fzf`][fzf]:
180
197
  source <(cdhist -i "cd -F fzf")
181
198
  ```
182
199
 
183
- Or, to use [`television`][television]:
200
+ Or, to use [`television`][television] with [`exa`][exa] to show a preview of
201
+ directory contents:
184
202
 
185
203
  ```sh
186
- source <(cdhist -i "cd -F \"tv --no-preview\"")
204
+ source <(cdhist -i "cd -uF \"tv --preview 'exa --color=always -l@F=always {}'\"")
187
205
  ```
188
206
 
189
207
  Now when you type `cd --` you will be prompted with a list of directories via
190
208
  your fuzzy finder so you can search for a directory to select by fuzzy text
191
209
  matching.
192
210
 
211
+ Note if you use [`television`][television] then it is suggested to set the
212
+ `television` option `input_bar_position = bottom` in the `ui` section of your
213
+ [`~/.config/television/config.toml`](https://github.com/alexpasmantier/television/blob/main/.config/config.toml)
214
+ file so that the input bar is at the bottom of the screen and close where your
215
+ terminal prompt usually is.
216
+
193
217
  In the following description, [`fzf`][fzf] will be used as it is by far the
194
218
  most popular fuzzy finder and the one used by the author. When you set up `fzf`
195
219
  [shell integration](https://junegunn.github.io/fzf/shell-integration/) then you
@@ -206,7 +230,7 @@ I disable that function in `fzf` by setting the `FZF_ALT_C_COMMAND` to an empty
206
230
  string before I source `fzf` in my `.bashrc` when [setting `fzf` up](https://junegunn.github.io/fzf/shell-integration/#setting-up-shell-integration).
207
231
 
208
232
  Then I set the following shell key binding in my `~/.inputrc` file (need to
209
- restart your shell to activate):
233
+ restart your login shell/terminal to activate):
210
234
 
211
235
  ```sh
212
236
  "\ec": "cd --\n"
@@ -239,6 +263,11 @@ you don't then just specify the full path, e.g:
239
263
  source <(cdhist -i "cd -F /path-to/fzf")
240
264
  ```
241
265
 
266
+ ### Yazi Integration
267
+
268
+ [`cdhist.yazi`][cdhist.yazi] is a [Yazi][yazi] plugin that provides cdhist
269
+ functionality within the [Yazi][yazi] terminal file manager.
270
+
242
271
  ### GIT Worktree Integration
243
272
 
244
273
  [cdhist](http://github.com/bulletmark/cdhist) can be used to easily `cd`
@@ -403,3 +432,6 @@ Public License at <http://www.gnu.org/licenses/> for more details.
403
432
  [fzy]: https://github.com/jhawthorn/fzy
404
433
  [skim]: https://github.com/skim-rs/skim
405
434
  [television]: https://github.com/alexpasmantier/television
435
+ [cdhist.yazi]: https://github.com/bulletmark/cdhist.yazi
436
+ [yazi]: https://yazi-rs.github.io/
437
+ [exa]: https://github.com/ogham/exa
@@ -6,6 +6,7 @@ build-backend = "setuptools.build_meta"
6
6
  name = "cdhist"
7
7
  description = "Program to provide a Linux cd history directory stack"
8
8
  readme = "README.md"
9
+ license = "GPL-3.0-or-later"
9
10
  requires-python = ">=3.8"
10
11
  keywords = ["bash", "zsh", "cd", "fzf", "git", "worktree"]
11
12
  classifiers = [
@@ -23,9 +24,6 @@ Homepage = "https://github.com/bulletmark/cdhist"
23
24
  [project.scripts]
24
25
  cdhist = "cdhist.cdhist:main"
25
26
 
26
- [project.license]
27
- text = "GPLv3"
28
-
29
27
  [tool.setuptools_scm]
30
28
  version_scheme = "post-release"
31
29
 
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes