brew tap sopamo/via https://github.com/sopamo/via
brew install sopamo/via/via
# Create an alias if you want to access via with v
echo "alias v=via" >> ~/.bash_aliases
source ~/.bash_aliases
# Coming soon, waiting for approval
snap install via-cli --classic
# Create an alias if you want to access via with v
echo "alias v=via-cli" >> ~/.bash_aliases
source ~/.bash_aliases
yay via-cli-bin
# Create an alias if you want to access via with v
echo "alias v=via-cli" >> ~/.bash_aliases
source ~/.bash_aliases
Create your first project configuration file by running v init my-project
and follow the instructions.
You can then run v my-project start
to start your project. Of course, you can rename the my-project.yaml file to match your project's name.
services:
database:
path: /Users/username/project/app
actions:
start: docker-compose up -d
stop: docker-compose down
You always have to specify the start and stop actions.
When running the start action, all other projects will be stopped automatically.
services:
app:
actions:
bash: docker-compose exec app bash
You can run individual actions like this:
v my-project app bash
First, follow the project setup instructions. Then, to run the project locally, install deno.
To run the code directly, run:
deno run --allow-read --allow-run --allow-env --allow-write ./src/via.ts [project] [service] [action]
To build the binary, run:
deno compile --allow-read --allow-run --allow-env --allow-write ./src/via.ts