Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/fabiospampinato/phoenix
My Phoenix setup. Powerful, easy to customize, tuned for web development, adds a space switcher.
https://github.com/fabiospampinato/phoenix
developer-tools macos phoenix productivity spaces switcher
Last synced: 3 months ago
JSON representation
My Phoenix setup. Powerful, easy to customize, tuned for web development, adds a space switcher.
- Host: GitHub
- URL: https://github.com/fabiospampinato/phoenix
- Owner: fabiospampinato
- License: mit
- Created: 2017-07-22T15:47:05.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2024-05-18T17:15:16.000Z (6 months ago)
- Last Synced: 2024-05-18T18:26:31.626Z (6 months ago)
- Topics: developer-tools, macos, phoenix, productivity, spaces, switcher
- Language: JavaScript
- Homepage:
- Size: 25.9 MB
- Stars: 401
- Watchers: 8
- Forks: 50
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
- awesome-starred-test - fabiospampinato/phoenix - My Phoenix setup. Powerful, easy to customize, tuned for web development, adds a space switcher. (JavaScript)
README
# Phoenix
My [Phoenix](https://github.com/kasper/phoenix) setup. Powerful, easy to customize, tuned for web development, adds a space switcher.
## Installation
This configuration uses a remap of the Caps Lock key to something more useful: the Hyper key ⇪ (basically just Ctrl + Alt + Cmd combined into one key) if used in combination with other keys, otherwise it gets mapped to F18, which is used to trigger the space switcher. If you prefer you may skip these remap steps while you try the configuration, but if you usually have many spaces opened I highly recommend you not to miss out the awesome space switcher, for which this hack is a requirement.
1. Install [Phoenix](https://github.com/kasper/phoenix#install)
2. Install [Karabiner Elements](https://github.com/tekezo/Karabiner-Elements) via its [dmg](https://pqrs.org/latest/karabiner-elements-latest.dmg)
3. Replace Caps Lock with Hyper/F18 using [this](http://tinyurl.com/yc8m5qe8) Karabiner Elements configuration (if the link doesn't work copy and paste this in a browser: `karabiner://karabiner/assets/complex_modifications/import?url=https%3A%2F%2Fraw.githubusercontent.com%2Ffabiospampinato%2Fphoenix%2Fmaster%2Fconfig%2Fkarabiner.json`)
4. `$ mkdir ~/.config`
5. `$ cd ~/.config`
6. `$ git clone [email protected]:fabiospampinato/phoenix.git`
7. Restart Phoenix
8. Enjoy!## Customization
To disable specific features, just comment out their correspondent `require` call in [phoenix.js](https://github.com/fabiospampinato/phoenix/blob/master/phoenix.js).
To tweak some numbers, simply edit [constants.js](https://github.com/fabiospampinato/phoenix/blob/master/config/constants.js).
Changing the specific shortcut used to trigger an action is pretty trivial.
Don't forget to make a PR if you fixed something or implemented something cool :)
## Shortcuts
### Sides
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + ↑ | Move window to the top side |
| ⇪ + → | Move window to the right side |
| ⇪ + ↓ | Move window to the bottom side |
| ⇪ + ← | Move window to the left side |### Corners
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + Q | Move window to the top-left corner |
| ⇪ + W | Move window to the top-right corner |
| ⇪ + S | Move window to the bottom-right corner |
| ⇪ + A | Move window to the bottom-left corner |### Halves
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + [ | Move window to the 1st half |
| ⇪ + ] | Move window to the 2nd half |### Thirds
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + 1 | Move window to the 1st column |
| ⇪ + 2 | Move window to the 2nd column |
| ⇪ + 3 | Move window to the 3rd column |### Sixths
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + Shift + Q | Move window to the 1st sixth |
| ⇪ + Shift + W | Move window to the 2nd sixth |
| ⇪ + Shift + E | Move window to the 3rd sixth |
| ⇪ + Shift + A | Move window to the 4th sixth |
| ⇪ + Shift + S | Move window to the 5th sixth |
| ⇪ + Shift + D | Move window to the 6th sixth |### Center
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + X | Center the window |
| ⇪ + Shift + X | Center the window and set its dimensions to 1280x800 |### Grow
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + Shift + ↑ | Grow window from the top |
| ⇪ + Shift + → | Grow window from the right |
| ⇪ + Shift + ↓ | Grow window from the bottom |
| ⇪ + Shift + ← | Grow window from the left |### Expand
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + Space | Toggle window expansion to fill the space |
| ⇪ + Shift + Space | Toggle window expansion to fullscreen |### Focus or Open
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + ` | Focus to or open [Notable](https://notable.md) |
| ⇪ + C | Focus to or open [Chrome](https://www.google.com/chrome) |
| ⇪ + D | Focus to or open [Chrome Developer Tools](https://developer.chrome.com/devtools) |
| ⇪ + V | Focus to or open [Visual Studio Code](https://code.visualstudio.com) |
| ⇪ + F | Focus to or open Finder |
| ⇪ + T | Focus to or open Terminal |
| ⇪ + G | Focus to or open [GitTower](https://www.git-tower.com/) |### Spaces
In order to make this work you have to open `System Preferences -> Keyboard -> Shortcuts -> Mission Control` and bind all `Switch to Desktop [NUMBER]` actions to Ctrl + Alt + Cmd + Shift + [NUMBER]. There are actions up to the 9th desktop, but they may not be shown to you if you have less then 9 desktops currently open.
**Note**: If you don't need wrapping support, you should just remap the `Move left/right a space` actions under `System Preferences -> Keyboard -> Shortcuts -> Mission Control`.
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + Tab | Switch to the next space |
| ⇪ + Shift + Tab | Switch to the previous space |### Applications Icons
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + I | For each window in the current space show an icon indicating its position |
| ⇪ + Shift + I | Display the current date and time |### Reload Phoenix
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + Shift + P | Reload Phoenix |### Pause/Resume Application
This can be used for saving battery, pausing single-player games etc.
| Shortcut | Description |
| -------- | ----------- |
| ⇪ + F8 | Pause or resume the current application |### Quit Application
Did you ever close 3+ Chrome windows instead of a single tab by mistake? Fear no more! Now in order to quit an app you have to trigger ⌘Q twice in a short timeframe. Stop [wasting 10$](https://clickontyler.com/commandq) for something so basic.
| Shortcut | Description |
| -------- | ----------- |
| ⌘Q ⌘Q | Quit application |## Mouse
### Snapping
Drag a window to an edge or corner to snap it into place.
## Magic
### Chrome
If it gets opened, positionate it to the left side.
### Chrome Developer Tools
If it gets opened, positionate it to the bottom-right corner, and shrink Visual Studio Code's height a bit, so that the console will be visible.
If it gets closed, restore Visual Studio Code's height.
### Terminal/iTerm2/Finder
If one of these apps' windows gets opened, positionate it to bottom-left corner.
### Visual Studio Code
If it gets opened, positionate it to the right side.
## Space Switcher
This is the truly great addition to what was already available on the internet.
It combines [Phoenix](https://github.com/kasper/phoenix), [Alfred](https://www.alfredapp.com) and [alfred-spaces-workflow](https://github.com/fabiospampinato/alfred-spaces-workflow) into the space switcher macOS deserves but never had, always just a double Hyper (⇪ ⇪) away.
This is how it works:
- It uses Phoenix to compile a list of your spaces
- It tries to guess a name for those spaces, by default that would be the name of the folder opened in the Visual Studio Code instance present in that space ([get_space_name.js](https://github.com/fabiospampinato/phoenix/blob/master/helpers/get_space_name.js))
- Refreshes the list and those guessed names when necessary
- Listens for the double Hyper (⇪ ⇪) shortcut
- Opens [Alfred](https://www.alfredapp.com) and triggers [alfred-spaces-workflow](https://github.com/fabiospampinato/alfred-spaces-workflow)
- Which reads the list of spaces compiled with Phoenix and displays it to you
- Now just select a space to switch toIn order to make this work you have to open `System Preferences -> Keyboard -> Shortcuts -> Mission Control` and bind all `Switch to Desktop [NUMBER]` actions to Ctrl + Alt + Cmd + Shift + [NUMBER]. There are actions up to the 9th desktop, but they may not be shown to you if you have less then 9 desktops currently open.
**Note**: There's no API available for retrieving windows from other spaces, therefor other spaces' guessed names won't be refreshed until you visit them. The very first time you load Phoenix you might want to switch the focus to all of them, one by one, to have their names updated.
## License
MIT © Fabio Spampinato