ppicker 0.1.0__py3-none-win_amd64.whl
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.
|
Binary file
|
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: ppicker
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Classifier: Development Status :: 4 - Beta
|
|
5
|
+
Classifier: Environment :: Console
|
|
6
|
+
Classifier: Programming Language :: Rust
|
|
7
|
+
Classifier: Topic :: Software Development
|
|
8
|
+
Summary: Fast project picker for tiling window managers (i3, sway): open a project in your editor
|
|
9
|
+
Keywords: project-manager,launcher,tui,i3,sway,rofi
|
|
10
|
+
Author: Roman
|
|
11
|
+
License: MIT
|
|
12
|
+
Requires-Python: >=3.8
|
|
13
|
+
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
|
|
14
|
+
Project-URL: Repository, https://github.com/roman-right/ppicker
|
|
15
|
+
|
|
16
|
+
# ppicker
|
|
17
|
+
|
|
18
|
+

|
|
19
|
+
|
|
20
|
+
Press a hotkey, type a few letters, hit Enter: the project opens in your editor.
|
|
21
|
+
No typing paths, no dozens of hotkeys, no remembering which editor goes with which project.
|
|
22
|
+
|
|
23
|
+
ppicker is a ~1 MB program that starts instantly. It was built as a popup for tiling window
|
|
24
|
+
managers (i3, sway) but works in any terminal, and through rofi, wofi, fuzzel or fzf if you
|
|
25
|
+
prefer those.
|
|
26
|
+
|
|
27
|
+
- Fuzzy search over project names and paths, with tag filters
|
|
28
|
+
- Opens the project in the editor you used last time, per project
|
|
29
|
+
- Shows the git branch and when you last opened each project
|
|
30
|
+
- Linux is the main target; macOS and Windows build and pass the tests in CI
|
|
31
|
+
|
|
32
|
+
## Quick start
|
|
33
|
+
|
|
34
|
+
**1. Install.** The command it gives you is `pp`.
|
|
35
|
+
|
|
36
|
+
```shell
|
|
37
|
+
pipx install ppicker # or: uv tool install ppicker
|
|
38
|
+
cargo install ppicker # alternative
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
**2. Tell it about your projects.**
|
|
42
|
+
|
|
43
|
+
```shell
|
|
44
|
+
pp scan ~/code # adds every git repository directly inside ~/code
|
|
45
|
+
pp add ~/work/shop # or add one by hand ("pp add ." for the current directory)
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
**3. Open the picker.**
|
|
49
|
+
|
|
50
|
+
```shell
|
|
51
|
+
pp
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
**4. Bind it to a key** so it pops up when you need it. See [i3 / sway](https://github.com/roman-right/ppicker#i3--sway).
|
|
55
|
+
|
|
56
|
+
## How it works
|
|
57
|
+
|
|
58
|
+
### Find a project
|
|
59
|
+
|
|
60
|
+
Start typing. ppicker matches against the project name *and* its path, so `shop` or `work/sh`
|
|
61
|
+
both find `~/work/shop`. The list narrows as you type, the best match is on top, and the matched
|
|
62
|
+
letters are highlighted. Projects you opened recently come first when the search box is empty.
|
|
63
|
+
|
|
64
|
+

|
|
65
|
+
|
|
66
|
+
The right-hand panel shows what you are about to open: the path, the current git branch, which
|
|
67
|
+
editor will be used, when you last opened it, and its tags. Press `Tab` to filter by a tag
|
|
68
|
+
(`work`, `personal`, ...) and `Shift-Tab` to go back.
|
|
69
|
+
|
|
70
|
+
### Open it
|
|
71
|
+
|
|
72
|
+
Press **Enter**. The project opens in its editor and ppicker closes. The editor is started in
|
|
73
|
+
the project's folder and keeps running on its own, so closing the terminal does not close it.
|
|
74
|
+
|
|
75
|
+
The first time you open a project, it uses your default editor, the first one in your config
|
|
76
|
+
(see [Editors](https://github.com/roman-right/ppicker#editors)). After that it uses whichever editor you opened it with last.
|
|
77
|
+
|
|
78
|
+
### Open it with a different editor
|
|
79
|
+
|
|
80
|
+
Press **→** (right arrow) instead of Enter to choose an editor for this one.
|
|
81
|
+
|
|
82
|
+

|
|
83
|
+
|
|
84
|
+
Pick one with the arrow keys and Enter, or press its number (`1`-`9`). The project opens, and
|
|
85
|
+
ppicker remembers your choice for next time.
|
|
86
|
+
|
|
87
|
+
### It remembers
|
|
88
|
+
|
|
89
|
+
Whichever editor you open a project with becomes that project's editor. The list shows it next
|
|
90
|
+
to each name, and Enter uses it.
|
|
91
|
+
|
|
92
|
+

|
|
93
|
+
|
|
94
|
+
So you can keep a Python service in PyCharm, your dotfiles in vim and everything else in VS Code,
|
|
95
|
+
and never think about it again. Just press Enter.
|
|
96
|
+
|
|
97
|
+
### Change the editor without opening the project
|
|
98
|
+
|
|
99
|
+
Press **Ctrl-e** to step the selected project to the next editor in your list. It is saved at
|
|
100
|
+
once and a note at the bottom tells you what changed. After the last editor it wraps back to your
|
|
101
|
+
default.
|
|
102
|
+
|
|
103
|
+

|
|
104
|
+
|
|
105
|
+
### Use rofi, wofi or fuzzel instead
|
|
106
|
+
|
|
107
|
+
If you already have a launcher you like, use it for the picking:
|
|
108
|
+
|
|
109
|
+
```shell
|
|
110
|
+
pp menu
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+

|
|
114
|
+
|
|
115
|
+
It lists your projects, you choose one, and it opens in the remembered editor. Add `--ask` to get
|
|
116
|
+
a second step where you choose the editor:
|
|
117
|
+
|
|
118
|
+
```shell
|
|
119
|
+
pp menu --ask
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+

|
|
123
|
+
|
|
124
|
+
For other launchers, pass the command to use: `pp menu --cmd "fuzzel --dmenu"` (or `wofi --dmenu`,
|
|
125
|
+
`fzf`). `{prompt}` in the command is replaced by the step name.
|
|
126
|
+
|
|
127
|
+
## Keys
|
|
128
|
+
|
|
129
|
+
| Key | What it does |
|
|
130
|
+
|---|---|
|
|
131
|
+
| type | search by name or path |
|
|
132
|
+
| `↑` `↓` (or `Ctrl-p` `Ctrl-n`) | move through the list |
|
|
133
|
+
| `Enter` | open the project in its editor |
|
|
134
|
+
| `→` | open with a different editor |
|
|
135
|
+
| `1`-`9` | in the editor list, open with that editor |
|
|
136
|
+
| `Ctrl-e` | switch the project's editor without opening it |
|
|
137
|
+
| `Tab` / `Shift-Tab` | next / previous tag filter |
|
|
138
|
+
| `Ctrl-u` | clear the search |
|
|
139
|
+
| `←` or `Esc` | back from the editor list; `Esc` in the main list quits |
|
|
140
|
+
|
|
141
|
+
## Editors
|
|
142
|
+
|
|
143
|
+
List the editors you use in the config file (run `pp paths` to see where it is). The first one is
|
|
144
|
+
the default for projects you have not opened yet:
|
|
145
|
+
|
|
146
|
+
```toml
|
|
147
|
+
ides = ["code", "pycharm", "vim"]
|
|
148
|
+
scan_dirs = ["/home/me/code"] # used by `pp scan` when you give no folder
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
An editor is just a command. ppicker runs `<command> .` inside the project folder, for example
|
|
152
|
+
`code .` or `pycharm .`. Anything that opens a folder works, including `idea`, `zed`, `subl`,
|
|
153
|
+
`nvim` (see the note below for terminal editors) or `code -n`.
|
|
154
|
+
|
|
155
|
+
> **Terminal editors** such as vim or nvim need a terminal to run in. Use a command that starts
|
|
156
|
+
> one, for example `ides = ["code", "alacritty -e nvim"]`.
|
|
157
|
+
|
|
158
|
+
## Commands
|
|
159
|
+
|
|
160
|
+
Everything the picker does is also available from the command line:
|
|
161
|
+
|
|
162
|
+
```shell
|
|
163
|
+
pp # open the picker
|
|
164
|
+
pp open myproj # open a project without the picker
|
|
165
|
+
pp open myproj pycharm # open with a specific editor (and remember it)
|
|
166
|
+
pp editor myproj # show which editor a project uses
|
|
167
|
+
pp editor myproj pycharm # set it without opening
|
|
168
|
+
pp editor myproj --reset # forget it, back to the default editor
|
|
169
|
+
pp add . --ide pycharm # register the current folder and set its editor
|
|
170
|
+
pp add . --name api -t work # custom name, add a tag (repeat -t for more)
|
|
171
|
+
pp scan ~/code -t work # add every git repository in a folder
|
|
172
|
+
pp list # show projects with their editors
|
|
173
|
+
pp rm myproj # remove from the list (files are untouched)
|
|
174
|
+
pp menu [--ask] # pick through rofi or another launcher
|
|
175
|
+
pp paths # where the config and project list are stored
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
`pp rm` only forgets the project; it never deletes anything on disk.
|
|
179
|
+
|
|
180
|
+
## i3 / sway
|
|
181
|
+
|
|
182
|
+
Open the picker in a small centred floating window on a hotkey. Add to `~/.config/i3/config`:
|
|
183
|
+
|
|
184
|
+
```
|
|
185
|
+
bindsym $mod+p exec --no-startup-id alacritty --class pp-popup,pp-popup -e pp
|
|
186
|
+
for_window [class="pp-popup"] floating enable, resize set 960 520, move position center
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
(In sway, use `app_id="pp-popup"` and `alacritty --class pp-popup` or `foot --app-id pp-popup`.)
|
|
190
|
+
|
|
191
|
+
Prefer rofi? One line is enough:
|
|
192
|
+
|
|
193
|
+
```
|
|
194
|
+
bindsym $mod+p exec --no-startup-id pp menu
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
## Where your data lives
|
|
198
|
+
|
|
199
|
+
Two small text files you can read and edit; `pp paths` prints the exact locations.
|
|
200
|
+
|
|
201
|
+
- `config.toml`: your settings (editors, scan folders).
|
|
202
|
+
- `projects.toml`: your projects, their tags, last-opened time and remembered editor.
|
|
203
|
+
|
|
204
|
+
## Moving from `code-compass`
|
|
205
|
+
|
|
206
|
+
ppicker replaces the old Qt-based `code-compass` package. See [docs/MIGRATION.md](https://github.com/roman-right/ppicker/blob/main/docs/MIGRATION.md)
|
|
207
|
+
for what changed and how to bring your projects over:
|
|
208
|
+
|
|
209
|
+
```shell
|
|
210
|
+
pipx install ppicker
|
|
211
|
+
pipx run code-compass==0.2.0 migrate
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
## Development
|
|
215
|
+
|
|
216
|
+
```shell
|
|
217
|
+
cargo test # unit tests
|
|
218
|
+
cargo clippy --all-targets -- -D warnings
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
A Linux end-to-end test that drives the real program inside i3 and rofi, and produces the
|
|
222
|
+
screenshots above, is described in [e2e/README.md](https://github.com/roman-right/ppicker/blob/main/e2e/README.md).
|
|
223
|
+
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
ppicker-0.1.0.data/scripts/pp.exe,sha256=RxCS6891SXkPP45e2BzddQJtLMQAtn9ZKHW6DjN4kmQ,922624
|
|
2
|
+
ppicker-0.1.0.dist-info/METADATA,sha256=9Gphk5UdVDvFew28_sT_J6DSsAY6ZJYvKwNXkMgLark,8693
|
|
3
|
+
ppicker-0.1.0.dist-info/WHEEL,sha256=Uvw7WSmy7Kj2FBk8Va4L_dq4MDW8X5Ynby-pOX3ZNS0,94
|
|
4
|
+
ppicker-0.1.0.dist-info/sboms/ppicker.cyclonedx.json,sha256=su9pNWYbs8S8laf_wdr_ubL5ZA8Vev-iW96a5rhQBOQ,206143
|
|
5
|
+
ppicker-0.1.0.dist-info/RECORD,,
|