https://github.com/derekahn/risk.alfredworkflow
🧮 Alfred workflow to calculate token amount to only "risk" a set dollar amount
https://github.com/derekahn/risk.alfredworkflow
Last synced: 10 months ago
JSON representation
🧮 Alfred workflow to calculate token amount to only "risk" a set dollar amount
- Host: GitHub
- URL: https://github.com/derekahn/risk.alfredworkflow
- Owner: derekahn
- License: mit
- Created: 2023-07-02T17:51:22.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2023-07-05T21:02:19.000Z (almost 3 years ago)
- Last Synced: 2025-03-29T11:35:58.937Z (over 1 year ago)
- Language: Rust
- Homepage:
- Size: 19.5 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 🧮 Risk Alfred Workflow
A simple [Alfred Workflow](https://www.alfredapp.com/workflows/) to calculate required tokens to only "risk" a set dollar amount.

> Big thank you to [@rossmacarthur](https://github.com/rossmacarthur) for creating [powerpack ⚡️](https://github.com/rossmacarthur/powerpack) 👏🏽
It requires 3 inputs:
1. Entry Price
2. Stop-Loss Price
3. Dollar Risk
It will calculate the required tokens and store it your clipboard 📋.
## 📦 Installation
### Pre-packaged
Grab the latest release from
[the releases page](https://github.com/derekahn/risk.alfredworkflow/releases).
Because the release contains an executable binary later versions of macOS will mark it as untrusted.
You can run the following to explicitly trust the release before installing to Alfred.
```bash
xattr -c ~/Downloads/risk-*-x86_64-apple-darwin.alfredworkflow
```
### Building from source
This workflow is written in Rust, so to install it from source you will first
need to install Rust and Cargo using [rustup](https://rustup.rs/). Then install
[powerpack](https://github.com/rossmacarthur/powerpack). Then you can run the
following to build an `.alfredworkflow` file.
```bash
git clone https://github.com/derekahn/risk.alfredworkflow.git
cd risk.alfredworkflow
powerpack package
```
The release will be available at `target/workflow/risk.alfredworkflow`.
## 🪪 License
This project is distributed under the terms of the MIT license.