Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/linksake/spotlight-scripts
🤖 A collection of scripts that can be executed via Spotlight.
https://github.com/linksake/spotlight-scripts
applescript osascript scripting spotlight zsh
Last synced: about 1 month ago
JSON representation
🤖 A collection of scripts that can be executed via Spotlight.
- Host: GitHub
- URL: https://github.com/linksake/spotlight-scripts
- Owner: LinkSake
- Created: 2021-11-17T18:09:01.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-02-16T21:42:35.000Z (almost 2 years ago)
- Last Synced: 2023-03-06T11:22:39.306Z (almost 2 years ago)
- Topics: applescript, osascript, scripting, spotlight, zsh
- Language: Shell
- Homepage:
- Size: 10.7 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Spotlight Scripts
A collection of scripts that can be executed via Spotlight.
## Usage
### Permitions
All the scripts need permitions to be executable by the user, this can be done by running `chmod -R u+x .` on the root directory of the project or using the `chmod-x-all.sh` script.
> All new scripts should be given permition after creation.
Then set the Terminal to automatically close the window upon completion, in the Terminal app go to `Preferences` > `Profiles` > (Select a Profile) > `Shell`; on `When the shell exits` choose `Close the window`.
The project can be anywhere on the system, just make sure Spotlight indexes the parent folder.
### Spotlight
Use the keybinding to open Spotlight (`cmd` + `space` by default) and type the name of the script (e.g.: sleep.sh.command) and hit enter to execute it; after sometime of using the scripts Spotlight will autocomplete them, then only typing the first part of the name will be enough (e.g.: sleep).
## Scripts
```shell
├── personal
│  └── morning.sh.command # Daily morning setup
├── spotify
│  ├── next.sh.command # Skips to next track on the queue
│  ├── pause.sh.command # Pauses current track
│  ├── play.sh.command # Plays current track
│  └── prev.sh.command # Rollback to previous track
├── system
│  ├── empty-tash.sh.command # Empties the trash bin
│  ├── quit-all.sh.command # Quits all open apps (WIP)
│  ├── screensaver.sh.command # Sets the screensaver on all screens
│  ├── shutdown.sh.command # Shuts down the system after prompting the password
│  └── sleep.sh.command # Sleeps the system
└── utils
├── chmod-x-all.sh # Makes every script on the folder executable from spotlight (WIP)
├── mk-demo.sh.command # Converts every .mov file in the desktop to .mp4
├── name-png.sh.command # Renames every .png image to demo.png
└── pomodoro.sh.command # Simple pomodoro timer (WIP)
```## Next up
Scripts that would be nice to make:
- Close specific app (like on Alfred).
- Close all apps (WIP).
- Play a song on Spotify by name.## Acknowledgements
Partially based on projects by [brendonjohn](https://github.com/brendonjohn/spotlight-scripts) and [gtumbaga](https://github.com/gtumbaga/Spotlight-Commands).
Pomodoro timer based on [pomo by Prayag2](https://github.com/Prayag2/pomo).