https://github.com/ChrisPenner/btt-quicknav
HTML overlay for quickly navigating your computer
https://github.com/ChrisPenner/btt-quicknav
bettertouchtool workflow
Last synced: 2 months ago
JSON representation
HTML overlay for quickly navigating your computer
- Host: GitHub
- URL: https://github.com/ChrisPenner/btt-quicknav
- Owner: ChrisPenner
- Created: 2018-05-01T06:31:28.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2018-06-03T18:11:04.000Z (almost 7 years ago)
- Last Synced: 2024-08-01T16:47:43.569Z (10 months ago)
- Topics: bettertouchtool, workflow
- Language: JavaScript
- Homepage:
- Size: 4.79 MB
- Stars: 19
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Better Touch Tool Quick-navigator
=================================**NOTE**: Requires latest alpha of [Better Touch Tool](https://folivora.ai/)
A quick navigator to automate your workflow;
Currently has commands to help you:
- Jump to bookmarks
- Open browser sessions (or presets)
- Open slack channels
- Run bash commands
## Installation
- `git clone https://github.com/ChrisPenner/btt-quicknav.git`
- `cd btt-quicknav`
- `npm install`## Setup
In order to use quick-nav you'll need to set it up with whatever commands or configuration you like.
Edit `src/config.js` to configure any commands you like!\*\* NOTE \*\* the default `src/config.js` is configured to show off how
certain commands work, but certain commands (e.g. pivotal, slack, project) won't work properly until you
configure them for your computer, or set YOUR API tokens/IDs in place.## Running
- `npm run build`: You'll need to set up your config files for this to succeed
- Add a new html overlay on some keyboard shortcut inside BTTBasic settings:
Advanced settings:
## Writing your own commands
Writing your own commands is easy! A command is simply a javascript object with the following fields; OR a javascript
Promise that resolves to an object with these fields (for doing API calls as part of your command)```javascript
{
title: 'My Command'
options: [{
label: "My first option's label",
value: "some-value"
}],
onSelect: ({label, value}) => {
// Here you can do whatever you want when someone selects an option
console.log('you ran the command with a label and value of:', label, value);
},
}
```I've already written a few helpers; see `src/commands/web-link-command.js` for a simple 'open browser' command, or
`src/commands/bash-command.js` for a command which helps you run bash commands on your computer. Each of these expose a
function which accepts an object with a `title` and `options` and build the appropriate command for you. Add each
command to your `src/command-config.js` and then `npm run build` for your new commands to show up.See `config.js` for examples!
## Troubleshooting
If nothing shows up when you hit your shortcut, it's possible the javascript has crashed. Try right-clicking where the
overlay should be and see if you get an option to `Inspect Element`; this will help you see what's going on. You can
also open the `build/index.html` in any normal browser to see what's happening.A common mistake is to forget that BTT caches the overlay and