Skip to content

Commit a34b8b1

Browse files
committed
Update Makefile
1 parent 2c65f20 commit a34b8b1

File tree

1 file changed

+14
-18
lines changed

1 file changed

+14
-18
lines changed

Diff for: Makefile

+14-18
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ tabBold := $(tab)$(boldText)
3030
help: ## Show this help.
3131
@awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z_-]+:.*?## / {sub("\\\\n",sprintf("\n%22c"," "), $$2);printf "\033[36m%-20s\033[0m %s\n", $$1, $$2}' $(MAKEFILE_LIST)
3232

33-
3433
test: banner ## Preview the modification
3534
@echo -e $(boldText)"\n\n##########" $(tab)DNS Control: preview$(tabNormal)"\n"
3635
@$(dnsControl) preview
@@ -42,22 +41,9 @@ build: banner ## Push the update to the nameservers
4241
@printf "\n\n"
4342

4443
secret: ## Inject secret via 1Password
45-
op inject -i ./lib/creds.json.tpl -o creds.json
46-
47-
ddns: ## ISPs dynamically update their customer’s IP addresses, let's identify the current one
48-
@# https://developers.cloudflare.com/dns/manage-dns-records/how-to/managing-dynamic-ip-addresses
49-
curl -o ip.json 'https://api.ipgeolocation.io/getip'
50-
51-
encrypt: ## Encrypt config file with a secret
52-
gpg --batch --passphrase $(secret) --symmetric config.js
53-
rm config.js
54-
ls config.*
55-
56-
decrypt: ## Decrypt config file
57-
gpg --batch --output config.js --passphrase $(secret) --decrypt config.js.gpg
58-
ls config.*
44+
op inject -i creds.json.tpl -o creds.json
5945

60-
gitCommit:
46+
commit:
6147
$(MAKE) triage
6248
@echo -e $(boldText)"\n\n##########" $(tab)Git add ${configFile}$(tabNormal)"\n"
6349
git add ${configFile}
@@ -67,7 +53,7 @@ gitCommit:
6753
git push
6854
@printf "\n\n"
6955

70-
gitArchive:
56+
archive:
7157
$(MAKE) banner
7258
$(MAKE) pull
7359
@echo -e $(boldText)"\n\n##########" $(tab)Archive ${configFile}$(tabNormal)"\n"
@@ -81,6 +67,16 @@ gitArchive:
8167
@printf "\n\n"
8268
$(MAKE) updateDNS
8369

70+
triage:
71+
$(MAKE) ticket
72+
@echo -e $(boldText)"\n\n##########" $(tab)Git add ${configFile}$(tabNormal)"\n"
73+
git add ${configFile}
74+
@echo -e $(boldText)"\n\n##########" $(tab)Git commit: $(gitMsg)$(tabNormal)"\n"
75+
git commit -m$(gitMsg)
76+
@echo -e $(boldText)"\n\n##########" $(tab)Git push$(tabNormal)"\n"
77+
git push
78+
@printf "\n\n"
79+
8480
clean: banner
8581
@echo -e $(boldText)"\n##########" $(tab)Remove dnsConfig.json and archive subFolder"\n"$(normalText)
8682
@$(RM) dnsConfig.json spfcache.json
@@ -97,7 +93,7 @@ banner:
9793
@printf "###################################################################################################\n\n"
9894

9995

100-
triage:
96+
ticket:
10197
ifdef ticket
10298
gitMsg = "Update DNS configurations with ticket \#"$(ticket)
10399
else ifdef msg

0 commit comments

Comments
 (0)