Skip to content

Commit

Permalink
update makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
pjaudiomv committed Nov 30, 2021
1 parent 26bbb4c commit 870a84d
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 107 deletions.
3 changes: 1 addition & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
.editorconfig export-ignore
.gitattributes export-ignore
.gitignore export-ignore
*.gif export-ignore
*.png export-ignore
assets/ export-ignore
27 changes: 0 additions & 27 deletions .github/workflows/release.yml

This file was deleted.

29 changes: 17 additions & 12 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,19 +1,24 @@
BINDIR = /usr/local/bin

.PHONY: build
build:
GOOS= GOARCH= GOARM= GOFLAGS= go build -o ${BINDIR}/_awsd_prompt
BINDIR = /usr/local/bin

help: ## Show this help
@fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//'

.PHONY: install
install: build
install: ## Install Target
GOOS= GOARCH= GOARM= GOFLAGS= go build -o ${BINDIR}/_awsd_prompt
chmod 755 ${BINDIR}/_awsd_prompt
cp scripts/_awsd ${BINDIR}/_awsd
@echo 'alias awsd="source _awsd"' >> ${HOME}/.zshrc
@echo 'alias awsd="source _awsd"' >> ${HOME}/.bashrc
@echo 'alias awsd="source _awsd"' >> ${HOME}/.bash_profile
@echo " -=-=--=-=-=-=-=-=-=-=-=-=-=-=- "
@echo " "
@echo " To Finish Installation add "
@echo " "
@echo " alias awsd=\"source _awsd\" "
@echo " "
@echo " to your bash profile or zshrc "
@echo " then open new terminal or "
@echo " source that file "
@echo " "
@echo " -=-=--=-=-=-=-=-=-=-=-=-=-=-=- "

.PHONY: uninstall
uninstall:
uninstall: ## Uninstall Target
rm -f ${BINDIR}/_awsd
rm -f ${BINDIR}/_awsd_prompt
16 changes: 11 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,24 @@ min go 1.16
brew tap pjauduiomv/awsd
brew install awsd
```
then add `alias awsd="source _awsd"` to your `~/.bash_profile` or `~/.zshrc`. Then source that file or open new terminal.


### from source
### Makefile

```sh
run install.sh
make install
```

open new terminal or source your `~/.bash_profile` or `~/.zshrc` config


### To Finish Installation
Add the following to your bash profile or zshrc then open new terminal or source that file

```sh
alias awsd="source _awsd"
```

Ex. `echo 'alias awsd="source _awsd"' >> ~/.zshrc`

## Usage
```sh
awsd
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/pjaudiomv/_awsd_prompt
module github.com/pjaudiomv/awsd

go 1.16

Expand Down
60 changes: 0 additions & 60 deletions install.sh

This file was deleted.

0 comments on commit 870a84d

Please sign in to comment.