Skip to content

Commit

Permalink
initial readme + some examples
Browse files Browse the repository at this point in the history
  • Loading branch information
aaabramov committed Nov 7, 2021
1 parent 3197c89 commit 37be6be
Show file tree
Hide file tree
Showing 4 changed files with 97 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
on: [ push, pull_request ]
name: Build
jobs:
test:
Build:
strategy:
matrix:
go-version: [ 1.17.x ]
Expand Down
32 changes: 31 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,32 @@
# goal
goal -- Go Aliases

GoAl -- Go Aliases

Start using:

Install via `brew`:

```shell
brew install #TODO
```

# Idea behind

1. Local alias management
To avoid typing repeatable commands
2. AssD - Aliases as a Documentation :D
No need to read through whole README file to start operating on you infrastructure

# Project plan

[ ] Add manual approve step
[ ] Add "environment" management to avoid tf-plan-dev, tf-plan-stage, tf-plan-prod, etc.
[ ] Add "depends on" other task like switch to dev?
[ ] Recursive dependencies
[ ] Assertions
[ ] ref output
[ ] recursive assertions
[ ] raw CLI output -- bad pattern?
[ ] Global aliases in `$HOME` directory?
[ ] Self-autocompletion via [https://github.com/posener/complete](complete) library
[ ] Generate ops-doc from commands
39 changes: 39 additions & 0 deletions examples/helm/goal.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
current-context:
desc: Current kubectl context
cmd: kubectl
args:
- config
- current-context

helm-upgrade-dev-dry-run:
desc: Dry run upgrade on dev
assert:
name: Check if on dev cluster
ref: current-context
equals: dev-cluster
cmd: helm
args:
- upgrade
- release-name
- -f
- values.yaml
- -f
- values/dev.yaml
- .
- --dry-run

helm-upgrade-dev:
desc: Upgrade on dev
assert:
name: Check if on dev cluster
ref: current-context
equals: dev-cluster
cmd: helm
args:
- upgrade
- release-name
- -f
- values.yaml
- -f
- values/dev.yaml
- .
26 changes: 26 additions & 0 deletions examples/terraform/goal.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
workspace:
desc: Current terraform workspace
cmd: terraform
args:
- workspace
- show

tf-plan-dev:
desc: Terraform plan for dev
assert:
name: Check if on dev workspace
ref: workspace
equals: dev
cmd: terraform
args:
- plan

tf-apply-dev:
desc: Terraform apply for dev
assert:
name: Check if on dev workspace
ref: workspace
equals: dev
cmd: terraform
args:
- plan

0 comments on commit 37be6be

Please sign in to comment.