Compare commits
696 Commits
| Author | SHA1 | Date |
|---|---|---|
|
|
e38696a0ac | |
|
|
af11a50854 | |
|
|
05ef68acbc | |
|
|
78f88406cf | |
|
|
feb468b517 | |
|
|
66ae9b0de8 | |
|
|
2e52d2a77c | |
|
|
4c2e644db1 | |
|
|
f0941e9ba2 | |
|
|
ad2b55804e | |
|
|
ec3c06fa33 | |
|
|
686a5e45cb | |
|
|
cfe46e3d36 | |
|
|
5f59cb5438 | |
|
|
7c7e4f90ec | |
|
|
1c9cfd056b | |
|
|
7c77223b15 | |
|
|
00062bfcb6 | |
|
|
bf2034d13d | |
|
|
c222e5001c | |
|
|
606272ac23 | |
|
|
d237ab9aa4 | |
|
|
0ab80429ce | |
|
|
8bedbe47a7 | |
|
|
e5e7785c96 | |
|
|
3294df5d3e | |
|
|
d770030513 | |
|
|
407f2f5b5f | |
|
|
5a62acd253 | |
|
|
129340d24d | |
|
|
2ef5d483e3 | |
|
|
03b3a977aa | |
|
|
c0dc83edfc | |
|
|
f2bc6c4e6d | |
|
|
4dddba3bc6 | |
|
|
c2698882e4 | |
|
|
135d480c7d | |
|
|
e11576f260 | |
|
|
d7fb6b3235 | |
|
|
35334cdcb0 | |
|
|
b95094153f | |
|
|
6ccd9f5adf | |
|
|
1ffbc85a62 | |
|
|
60c4c0b598 | |
|
|
088212fd32 | |
|
|
d1b831a92d | |
|
|
69407018a7 | |
|
|
a481ff41ab | |
|
|
7cc2ced3b9 | |
|
|
66fbed7f6f | |
|
|
6b0ca17df0 | |
|
|
23efb39fb0 | |
|
|
9a71556b99 | |
|
|
e1ddf6e311 | |
|
|
0068315c35 | |
|
|
b839294827 | |
|
|
634c1f8c18 | |
|
|
4686ce1f12 | |
|
|
a6fd93076d | |
|
|
13531c9534 | |
|
|
77c135956d | |
|
|
23ac376f10 | |
|
|
ec6d371db8 | |
|
|
db6fd42104 | |
|
|
f2b4d82527 | |
|
|
6ba527ff98 | |
|
|
55e698a737 | |
|
|
3a778072db | |
|
|
866e5be86b | |
|
|
1c2fc2837f | |
|
|
4e0e59230b | |
|
|
6ca10cf84c | |
|
|
33505d4db1 | |
|
|
09e8c25b64 | |
|
|
ad1d73aaa1 | |
|
|
ca8101b34a | |
|
|
9dece7fe58 | |
|
|
49649c5f0c | |
|
|
6a53066b05 | |
|
|
53e5965f2d | |
|
|
999b787c92 | |
|
|
0286a50fcd | |
|
|
f7cba27f10 | |
|
|
029e53a433 | |
|
|
6d422f17e4 | |
|
|
dc380e9ed6 | |
|
|
6734baf950 | |
|
|
df87b41635 | |
|
|
7762aa687a | |
|
|
c9efc161ff | |
|
|
d86a182b6e | |
|
|
c6ac9109d7 | |
|
|
2b3af0d8c9 | |
|
|
ac0d91b682 | |
|
|
1d73537dbf | |
|
|
6bacd5fb1c | |
|
|
fbc5d0a5af | |
|
|
0e0e0d3035 | |
|
|
a9dda3d358 | |
|
|
0d55a2406c | |
|
|
f0dfe1a67f | |
|
|
b686515877 | |
|
|
a36a4c4038 | |
|
|
fbf7efa1b8 | |
|
|
4a9df8ec88 | |
|
|
6e2e0af7f9 | |
|
|
beac9c430a | |
|
|
fd91211704 | |
|
|
629a1b0c0d | |
|
|
e5cd10112c | |
|
|
1ddec65d56 | |
|
|
425ef3e10a | |
|
|
2a95e983d0 | |
|
|
c837232643 | |
|
|
de31a308f9 | |
|
|
fd1771d45c | |
|
|
cb9b999f06 | |
|
|
014c102b71 | |
|
|
fdff1d81cd | |
|
|
5c592c9a6f | |
|
|
1722ea963e | |
|
|
be755d63af | |
|
|
be9a838015 | |
|
|
34bc37c178 | |
|
|
789ede9ef3 | |
|
|
604f9b0baa | |
|
|
47bbc73744 | |
|
|
5957d189ea | |
|
|
fe48deda2d | |
|
|
6257853759 | |
|
|
72829ca21d | |
|
|
ffcf8f1c94 | |
|
|
fbd842b2ea | |
|
|
df1881acfa | |
|
|
2927f672fd | |
|
|
33bade22b7 | |
|
|
1c8ad2c1b7 | |
|
|
ee853670a1 | |
|
|
41cf3cfaf2 | |
|
|
e05fa477d7 | |
|
|
150f73ee50 | |
|
|
2cea663a4a | |
|
|
95353f1a98 | |
|
|
ddf75f17ac | |
|
|
35ecc260c2 | |
|
|
31751624c0 | |
|
|
e7818dbaca | |
|
|
60c10004d1 | |
|
|
8246794a28 | |
|
|
c1943192ce | |
|
|
a93919625d | |
|
|
6b08284928 | |
|
|
187916d903 | |
|
|
caae145f5a | |
|
|
379813b671 | |
|
|
9d6fe72267 | |
|
|
0b1c65b100 | |
|
|
b550b99160 | |
|
|
b3ef9ea209 | |
|
|
e7b91e7be5 | |
|
|
61b6393a4a | |
|
|
4ba11dbaa2 | |
|
|
562eb6ce68 | |
|
|
78da4ca760 | |
|
|
c982a881a2 | |
|
|
12a734cb49 | |
|
|
27bfc966ac | |
|
|
604e5c5040 | |
|
|
665d9e96a8 | |
|
|
8d30275b8a | |
|
|
ea6cb6afec | |
|
|
826916be4f | |
|
|
11aa32387e | |
|
|
5748aa20a7 | |
|
|
7c2c2a5525 | |
|
|
16bf32be65 | |
|
|
0619c19f65 | |
|
|
363827a3b5 | |
|
|
561e282585 | |
|
|
89c9504a5e | |
|
|
ee135d28da | |
|
|
253004a599 | |
|
|
23f9b7416a | |
|
|
98889b208c | |
|
|
146107926e | |
|
|
5d5858058e | |
|
|
f6119567e8 | |
|
|
267a721ac6 | |
|
|
8052911861 | |
|
|
70dbda053b | |
|
|
2b8928f2bd | |
|
|
00e3955dd3 | |
|
|
a9a40a3cad | |
|
|
d6555f369a | |
|
|
1480cdfa34 | |
|
|
bc95eceb10 | |
|
|
0d346b204f | |
|
|
dfe681d223 | |
|
|
eb91f4ec69 | |
|
|
a4e41badf1 | |
|
|
4dbe92e38d | |
|
|
43df0fe130 | |
|
|
302bae9c5f | |
|
|
23f7916a4d | |
|
|
cade0a1e7a | |
|
|
1e77c26c00 | |
|
|
880488ec9a | |
|
|
b0862899d7 | |
|
|
7fcad6ed0d | |
|
|
d214621d39 | |
|
|
b0f23d8e98 | |
|
|
578c702ca3 | |
|
|
2a9ee7e344 | |
|
|
39e5652ee5 | |
|
|
1d6f4d747b | |
|
|
c794f4f0e7 | |
|
|
26b402e254 | |
|
|
4cf2aae36e | |
|
|
b8694ee140 | |
|
|
8939e943c5 | |
|
|
64efe52394 | |
|
|
afeb4d6e11 | |
|
|
5478617a89 | |
|
|
85a77f1e46 | |
|
|
bf4ddf5951 | |
|
|
399f0265aa | |
|
|
5f19de8d51 | |
|
|
16cee1956d | |
|
|
2a8d8ba540 | |
|
|
b87f3067b5 | |
|
|
fd7b20b8d7 | |
|
|
75d22d865f | |
|
|
c08267e25d | |
|
|
7e79212dff | |
|
|
2343e2dd35 | |
|
|
d1d7cd4383 | |
|
|
056c392a54 | |
|
|
0c24edae06 | |
|
|
3c2bc3d196 | |
|
|
5a849419ba | |
|
|
3cb5f3f7e6 | |
|
|
eeaf59b439 | |
|
|
ae8c9c08a3 | |
|
|
7770e8cbb9 | |
|
|
9f146f937a | |
|
|
7a0b353cea | |
|
|
2575d64deb | |
|
|
44a1b55db7 | |
|
|
878bbe5942 | |
|
|
dd83efc35f | |
|
|
035eabade6 | |
|
|
80c52b4c25 | |
|
|
dcb7038ca3 | |
|
|
457a279263 | |
|
|
b1e922ea38 | |
|
|
4779c8c380 | |
|
|
5f9a3f143f | |
|
|
2f4ed49a71 | |
|
|
e1e971c0ea | |
|
|
3874ad85c2 | |
|
|
d7695d5456 | |
|
|
dbb3ea4736 | |
|
|
edc36795b5 | |
|
|
7e54aea8c7 | |
|
|
4ba1ab9fd7 | |
|
|
18536ed892 | |
|
|
21942f6275 | |
|
|
a312e5a9b9 | |
|
|
a78d72eed1 | |
|
|
46df804ad9 | |
|
|
1ec48c8d71 | |
|
|
ea2002a2e4 | |
|
|
0f0093dd4b | |
|
|
dfc3fa4339 | |
|
|
62b5297dc2 | |
|
|
22b290b94f | |
|
|
bc25810069 | |
|
|
805eab804c | |
|
|
4719e43d0b | |
|
|
251e23a3fa | |
|
|
317ff77810 | |
|
|
550f808884 | |
|
|
4c473853e9 | |
|
|
003b0ce802 | |
|
|
6ed006a167 | |
|
|
5eab3bd288 | |
|
|
9b51dc0b5f | |
|
|
180fb93df8 | |
|
|
973a1f9b40 | |
|
|
e116288b83 | |
|
|
fd35094463 | |
|
|
8d5d9073ce | |
|
|
bdf9a2bca3 | |
|
|
77c5f8eda9 | |
|
|
1a48bcc852 | |
|
|
27ebc585be | |
|
|
8e8fe69db4 | |
|
|
9291b46b15 | |
|
|
d4b4995e2a | |
|
|
7430a06ec2 | |
|
|
2b5e531396 | |
|
|
4f700dfb3b | |
|
|
c3eaa606de | |
|
|
e3bd30f98d | |
|
|
e71ea4ad02 | |
|
|
6dec28b5df | |
|
|
b772e6ace7 | |
|
|
dc45958a8e | |
|
|
bdaf29f84c | |
|
|
6e480d7a8a | |
|
|
86c1e3c043 | |
|
|
f2bff34493 | |
|
|
1fd601db7f | |
|
|
21e7c1f00c | |
|
|
af801cfadc | |
|
|
46f343461c | |
|
|
4ec1b5f3e7 | |
|
|
fcbe4e90b7 | |
|
|
c7c447a54b | |
|
|
262e55eda2 | |
|
|
6db5f38f6e | |
|
|
079652e6e7 | |
|
|
2fe9e01051 | |
|
|
ce22710e00 | |
|
|
b1b08de626 | |
|
|
04c7424de5 | |
|
|
5fab574bfd | |
|
|
e7c3263f12 | |
|
|
776d0b7d37 | |
|
|
ae5131aee2 | |
|
|
bb69edd795 | |
|
|
8a226a73f1 | |
|
|
30ca1bfba2 | |
|
|
97ef5a8087 | |
|
|
61e1d6aec2 | |
|
|
c35ed44cbf | |
|
|
21a2198a12 | |
|
|
6030767b4e | |
|
|
da6b27166f | |
|
|
9dcbeec7ad | |
|
|
b2279b7237 | |
|
|
b846c86dbb | |
|
|
2e968c459c | |
|
|
6fc47a7671 | |
|
|
931f27ee3e | |
|
|
2728f20354 | |
|
|
a538844c3b | |
|
|
c060eb46ea | |
|
|
dba610cdc8 | |
|
|
5d68fca7e5 | |
|
|
48a1ff7fb4 | |
|
|
682b51c195 | |
|
|
9d8002226d | |
|
|
139baedf5d | |
|
|
f2dcb2aff6 | |
|
|
3695862b43 | |
|
|
d1b7166358 | |
|
|
9f79848eed | |
|
|
1305a86136 | |
|
|
201827ddff | |
|
|
c81c9dcc8c | |
|
|
f0abc3fbc4 | |
|
|
29216c0fd4 | |
|
|
dd911f1256 | |
|
|
c030f2108b | |
|
|
a99b597217 | |
|
|
d6bcedfa96 | |
|
|
02b57a83ef | |
|
|
45aeb86c21 | |
|
|
03653fc141 | |
|
|
caa0d48c60 | |
|
|
db9027989d | |
|
|
75aabd5d20 | |
|
|
dc5c9e107c | |
|
|
290aab4efe | |
|
|
8b308df939 | |
|
|
71b4f3c1bc | |
|
|
d8e7b173b5 | |
|
|
4abafc55ef | |
|
|
2e51e92699 | |
|
|
c5d3b258ab | |
|
|
2dd4426a7c | |
|
|
c852360a39 | |
|
|
f534505357 | |
|
|
475952dbb9 | |
|
|
33df3a2bcd | |
|
|
f03a89836e | |
|
|
45e8c4e3cd | |
|
|
2a2cc72541 | |
|
|
1c03eb6b3b | |
|
|
64f75ce22d | |
|
|
3fe9c8d6bc | |
|
|
e38eeefc5f | |
|
|
c0aad51afd | |
|
|
1c3a7ffdb3 | |
|
|
2991aa66ca | |
|
|
c323357067 | |
|
|
e560e88814 | |
|
|
895102edeb | |
|
|
4bc83d7940 | |
|
|
2c14a18483 | |
|
|
c769234350 | |
|
|
6a41dbc3f6 | |
|
|
fdb50aec6b | |
|
|
559cde151b | |
|
|
84383cb46b | |
|
|
8edbdf9bbd | |
|
|
1065d98dbe | |
|
|
476159eab9 | |
|
|
15fe122c1f | |
|
|
4d821338a3 | |
|
|
9c4f7773b9 | |
|
|
5b29d3c6e6 | |
|
|
1bc56b1d8f | |
|
|
51042c2cf0 | |
|
|
1882f50aa1 | |
|
|
2c8ee40566 | |
|
|
bdb5289660 | |
|
|
036cf8ada0 | |
|
|
1273504267 | |
|
|
8784ed2785 | |
|
|
a89f2f8f13 | |
|
|
447c89aa0e | |
|
|
2a23598873 | |
|
|
7b4056fdf9 | |
|
|
1ff2497c9e | |
|
|
ab3b8b8f22 | |
|
|
daaab1b73d | |
|
|
98bd0ae149 | |
|
|
c90a6283ef | |
|
|
a14d9cb6ea | |
|
|
bdfb987f0c | |
|
|
9ce199c251 | |
|
|
00f5f2a62e | |
|
|
2d1bd82575 | |
|
|
5e3810ac96 | |
|
|
5feebcc9d9 | |
|
|
b0e8729b0f | |
|
|
253d1213e0 | |
|
|
b8ee63c67d | |
|
|
b986c39040 | |
|
|
7987e4bfcd | |
|
|
7911f770cf | |
|
|
bb3a51f742 | |
|
|
413d7a1326 | |
|
|
7cd02781f8 | |
|
|
f7cc442af4 | |
|
|
48c17e95c3 | |
|
|
953e422bed | |
|
|
d6239cf190 | |
|
|
49698e269a | |
|
|
adab880f89 | |
|
|
c3d333ddc4 | |
|
|
cf08fcaff2 | |
|
|
c3382c7b50 | |
|
|
07384bcf7c | |
|
|
b7feb14404 | |
|
|
cd38f32d95 | |
|
|
4c4b138671 | |
|
|
7fc003b7d6 | |
|
|
e1017513d0 | |
|
|
1ae407150c | |
|
|
337e188d25 | |
|
|
81b17f795b | |
|
|
6a923760d8 | |
|
|
c710fc783a | |
|
|
b2ee5f96a5 | |
|
|
d4ec41bef7 | |
|
|
df560ca04a | |
|
|
f78139fc05 | |
|
|
2e3fe0a1ea | |
|
|
cea95d72b3 | |
|
|
7f60b73a2a | |
|
|
956ca517f4 | |
|
|
eaa2f829bd | |
|
|
41cba9d7e4 | |
|
|
ffeb770593 | |
|
|
6e03a726a6 | |
|
|
7fb7bb9cb8 | |
|
|
008c2b30ac | |
|
|
c360f0c7c5 | |
|
|
ec075a404a | |
|
|
3eed0f033f | |
|
|
8a1dc96bc0 | |
|
|
c2c76a380a | |
|
|
127cbbd4e3 | |
|
|
05aac8ef39 | |
|
|
002a23c758 | |
|
|
37577550e1 | |
|
|
198df8044a | |
|
|
a4e4f30ff1 | |
|
|
b0750fa49f | |
|
|
e22aac855e | |
|
|
92282c4795 | |
|
|
2ada414266 | |
|
|
b897c7d3ce | |
|
|
2ddb40751f | |
|
|
84c96665ce | |
|
|
5857648377 | |
|
|
55be49e887 | |
|
|
e8966ea2a5 | |
|
|
d6c4c0cc88 | |
|
|
7ed12083f2 | |
|
|
0471a20c7c | |
|
|
be90e655f1 | |
|
|
e5e7c7c55b | |
|
|
8a81fd7271 | |
|
|
6e2e945771 | |
|
|
8c697715eb | |
|
|
4700d7bf05 | |
|
|
4984d7adc8 | |
|
|
fb6e05d915 | |
|
|
8a03f451b2 | |
|
|
a2e32f37c5 | |
|
|
eabdf41b83 | |
|
|
8e9438d715 | |
|
|
699720fe8b | |
|
|
679d8b10b6 | |
|
|
0ad1af8306 | |
|
|
88d66bbfca | |
|
|
6618457f9e | |
|
|
699d893bef | |
|
|
dca96e0c39 | |
|
|
bb555aefbf | |
|
|
ef0c64322f | |
|
|
c98424308a | |
|
|
b038ea5869 | |
|
|
f0179c79ce | |
|
|
a31145335e | |
|
|
cff6f3464a | |
|
|
b14bb4735e | |
|
|
ccd8b52e89 | |
|
|
c29eb16dfc | |
|
|
5eccc59d27 | |
|
|
757a5bf25b | |
|
|
cace3a591d | |
|
|
8e169388d2 | |
|
|
e2915df1e5 | |
|
|
de58fdd73f | |
|
|
39d6488c6b | |
|
|
3e2ec1232d | |
|
|
635e5488ba | |
|
|
e701660ff1 | |
|
|
9378a8318f | |
|
|
a7955b972c | |
|
|
f6c5717a7a | |
|
|
a375e7131e | |
|
|
77e9404c7d | |
|
|
8d1e802565 | |
|
|
5fc418e479 | |
|
|
1f6d6aa147 | |
|
|
0dbf1d593c | |
|
|
1c3cbf7ca6 | |
|
|
b48f3fd7d3 | |
|
|
b72588edfd | |
|
|
435151819f | |
|
|
470341b23a | |
|
|
dee55a03cc | |
|
|
f9de8d170a | |
|
|
99eab7a76c | |
|
|
9d656747a9 | |
|
|
ffe15ebfe0 | |
|
|
476fcb4325 | |
|
|
f0690c09fb | |
|
|
9c1dbbcf12 | |
|
|
8c0860588d | |
|
|
ec3b8d645f | |
|
|
c6f6d8c27a | |
|
|
9ea60020ae | |
|
|
feacd560b6 | |
|
|
ecfcaba32e | |
|
|
5782325dea | |
|
|
85408743fa | |
|
|
3654198deb | |
|
|
0c412442f5 | |
|
|
cd65e0925f | |
|
|
bd9f4015a7 | |
|
|
8fb75cf0e3 | |
|
|
0eff44930c | |
|
|
233fcc3091 | |
|
|
f71fa5be2c | |
|
|
5001995e92 | |
|
|
bcd67db4ab | |
|
|
02c13b7921 | |
|
|
8b3867fe35 | |
|
|
0f28824ad5 | |
|
|
65ef8e2e8b | |
|
|
9e255c2139 | |
|
|
226454b069 | |
|
|
9566a3ec18 | |
|
|
caec973c18 | |
|
|
9cc36de58e | |
|
|
67eff71d72 | |
|
|
907fa1de96 | |
|
|
6ee4cb4597 | |
|
|
de9ea54b81 | |
|
|
e321a3d657 | |
|
|
a6d58351e7 | |
|
|
0fb9d0c090 | |
|
|
893c8dbb96 | |
|
|
43947e2cbc | |
|
|
9ea290a5ed | |
|
|
e89403d59b | |
|
|
61c0357414 | |
|
|
e13f7d1b07 | |
|
|
aad58bc910 | |
|
|
d4ebba174c | |
|
|
0f3e4dc8be | |
|
|
e51fe1fe2b | |
|
|
d979c32c8a | |
|
|
f6e3fc358c | |
|
|
e70211549f | |
|
|
a3f5b5f29a | |
|
|
682fd32a13 | |
|
|
01b916c544 | |
|
|
2444a57cc5 | |
|
|
9b62a5c4df | |
|
|
1e6113f7b7 | |
|
|
9f4c71d40f | |
|
|
dff892e0a3 | |
|
|
2ae0350f5d | |
|
|
b65a7cc67c | |
|
|
7f193a2e05 | |
|
|
8c47706139 | |
|
|
2120be9372 | |
|
|
476c568566 | |
|
|
26118d1835 | |
|
|
d3bb347786 | |
|
|
b8da4cb68c | |
|
|
940739a8a0 | |
|
|
716b49fa0e | |
|
|
e15b53ea61 | |
|
|
1b7448bc9d | |
|
|
d0aa9cb542 | |
|
|
c731e45770 | |
|
|
7b8dbd39bc | |
|
|
31bea24da6 | |
|
|
7cd94e1f7f | |
|
|
370c5b349e | |
|
|
c0fa514f7d | |
|
|
409e18f7cb | |
|
|
5e723842b8 | |
|
|
7e620fed63 | |
|
|
58f2240789 | |
|
|
2201f6658b | |
|
|
c7f125a85d | |
|
|
80f143c90b | |
|
|
5d809dd73d | |
|
|
ebe59c9adc | |
|
|
a6e2c2fc13 | |
|
|
6678788f19 | |
|
|
4f0fa7ebe7 | |
|
|
905abd37f8 | |
|
|
a8b43620f8 | |
|
|
0239ab8c31 | |
|
|
1dfaf36d91 | |
|
|
e06066c367 | |
|
|
035fc920ad | |
|
|
ab011cd9ba | |
|
|
d42a1206f9 | |
|
|
ce854255b4 | |
|
|
9524bf85ae | |
|
|
6866648ac6 | |
|
|
514a753901 | |
|
|
e481eb41e5 | |
|
|
a3ae37b385 | |
|
|
0b808b17f1 | |
|
|
ed97b9d51f | |
|
|
19db142aae | |
|
|
4860fb8c60 | |
|
|
cda81f3d74 | |
|
|
7331cd2676 | |
|
|
399b5199b0 | |
|
|
eced6802d0 | |
|
|
02f6654841 | |
|
|
7b5f758eba | |
|
|
64c4c30706 | |
|
|
ea444459cf | |
|
|
6f02b8d194 | |
|
|
c8ef6c9146 | |
|
|
8ae2b1e73d | |
|
|
ffc1701c0a | |
|
|
682d6d728d | |
|
|
96586dd575 | |
|
|
c59886b8ab | |
|
|
5c6306deb7 | |
|
|
6093ecbb60 | |
|
|
e289549a50 | |
|
|
9d7738d14d | |
|
|
7827907154 | |
|
|
0ed6f045f6 | |
|
|
64d827c3da | |
|
|
a30a76906c | |
|
|
e89948a7f0 | |
|
|
e25e371ba7 | |
|
|
e4e0c151b2 |
|
|
@ -13,18 +13,24 @@ insert_final_newline = true
|
||||||
trim_trailing_whitespace = false
|
trim_trailing_whitespace = false
|
||||||
|
|
||||||
[.git*]
|
[.git*]
|
||||||
|
indent_size = tab
|
||||||
indent_style = tab
|
indent_style = tab
|
||||||
|
|
||||||
[{**.*sh,test/run}]
|
[{**.*sh,test/run,**.bats}]
|
||||||
|
indent_size = tab
|
||||||
indent_style = tab
|
indent_style = tab
|
||||||
indent_size = 4
|
|
||||||
|
|
||||||
shell_variant = bash
|
shell_variant = bash
|
||||||
binary_next_line = true # like -bn
|
binary_next_line = true # like -bn
|
||||||
switch_case_indent = true # like -ci
|
switch_case_indent = true # like -ci
|
||||||
space_redirects = true # like -sr
|
space_redirects = true # like -sr
|
||||||
keep_padding = false # like -kp
|
keep_padding = false # like -kp
|
||||||
end_of_line = lf
|
end_of_line = lf
|
||||||
charset = utf-8
|
charset = utf-8
|
||||||
trim_trailing_whitespace = true
|
trim_trailing_whitespace = true
|
||||||
insert_final_newline = true
|
insert_final_newline = true
|
||||||
|
|
||||||
|
[**.bats]
|
||||||
|
indent_size = tab
|
||||||
|
indent_style = tab
|
||||||
|
shell_variant = bats
|
||||||
|
|
|
||||||
|
|
@ -1,46 +0,0 @@
|
||||||
---
|
|
||||||
name: Bug report
|
|
||||||
about: Create a bug report to help us improve
|
|
||||||
title: ''
|
|
||||||
labels: bug:general
|
|
||||||
assignees: ''
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
<!--- Provide a general summary of the issue in the Title above -->
|
|
||||||
|
|
||||||
## Expected Behavior
|
|
||||||
<!--- Tell us what should happen -->
|
|
||||||
|
|
||||||
## Current Behavior
|
|
||||||
<!--- Tell us what happens instead of the expected behavior -->
|
|
||||||
|
|
||||||
## Possible Solution
|
|
||||||
<!--- Not obligatory, but suggest a fix/reason for the bug, -->
|
|
||||||
|
|
||||||
## Context
|
|
||||||
<!--- How has this issue affected you? What are you trying to accomplish? -->
|
|
||||||
<!--- Providing context helps us come up with a solution that is most useful in the real world -->
|
|
||||||
|
|
||||||
## Steps to Reproduce
|
|
||||||
<!--- Provide a link to a live example, or an unambiguous set of steps to -->
|
|
||||||
<!--- reproduce this bug. Include code to reproduce, if relevant -->
|
|
||||||
1.
|
|
||||||
2.
|
|
||||||
3.
|
|
||||||
4.
|
|
||||||
|
|
||||||
## Your Environment
|
|
||||||
<!--- Include as many relevant details about the environment you experienced the bug in -->
|
|
||||||
* Bash-it version used:
|
|
||||||
* List of enabled plugins, themes and aliases (use ``bash-it show (plugins/themes/aliases)``):
|
|
||||||
* ``bash-it doctor`` output:
|
|
||||||
* Bash version:
|
|
||||||
* Operating System and version:
|
|
||||||
|
|
||||||
## Your Bash Config File
|
|
||||||
<!--- Please paste here your bash config file (.bashrc/.bash_profile) -->
|
|
||||||
<!--- This will help us debug and locate the problem -->
|
|
||||||
```bash
|
|
||||||
# Your bash config file should be here
|
|
||||||
```
|
|
||||||
|
|
@ -0,0 +1,85 @@
|
||||||
|
name: 🐛 Bug report
|
||||||
|
title: "[Bug]: "
|
||||||
|
description: Create a bug report to help us improve
|
||||||
|
labels: "bug:general"
|
||||||
|
body:
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Expected behavior
|
||||||
|
description: Tell us what should happen.
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Current behavior
|
||||||
|
description: Tell us what happens instead of the expected behavior.
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Possible solution
|
||||||
|
description: Tell us how it could be fixed at your glance.
|
||||||
|
validations:
|
||||||
|
required: false
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Context
|
||||||
|
description: >
|
||||||
|
How has this issue affected you? What are you trying to accomplish?
|
||||||
|
Providing context helps us come up with a solution that is most useful in the real world.
|
||||||
|
validations:
|
||||||
|
required: false
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Steps to reproduce
|
||||||
|
description: >
|
||||||
|
Provide a link to a live example, or an unambiguous set of steps to reproduce this bug. Include code to reproduce, if relevant.
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: input
|
||||||
|
attributes:
|
||||||
|
label: Bash-it version
|
||||||
|
placeholder: "How to get: bash-it version"
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: input
|
||||||
|
attributes:
|
||||||
|
label: List of enabled plugins, themes and aliases
|
||||||
|
placeholder: "How to get: bash-it show plugins|themes|aliases (it is not a pipe)"
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: input
|
||||||
|
attributes:
|
||||||
|
label: Bash version
|
||||||
|
placeholder: "How to get: bash --version"
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: input
|
||||||
|
attributes:
|
||||||
|
label: Operating system and version
|
||||||
|
placeholder: "How to get: neofetch (or another command)"
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: "bash-it doctor output"
|
||||||
|
value: |
|
||||||
|
```
|
||||||
|
# How to get: bash-it doctor
|
||||||
|
```
|
||||||
|
validations:
|
||||||
|
required: false
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Your ~/.bashrc
|
||||||
|
value: |
|
||||||
|
```bash
|
||||||
|
# How to get: cat ~/.bashrc
|
||||||
|
```
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Notes
|
||||||
|
description: >
|
||||||
|
Provide any extra details here.
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
blank_issues_enabled: true
|
||||||
|
contact_links:
|
||||||
|
- name: Libera chat
|
||||||
|
url: https://web.libera.chat/?channel=#bash-it
|
||||||
|
about: You can ask and answer questions here
|
||||||
|
|
@ -1,23 +0,0 @@
|
||||||
---
|
|
||||||
name: Feature request
|
|
||||||
about: Suggest an idea for this project
|
|
||||||
title: ''
|
|
||||||
labels: feature request
|
|
||||||
assignees: ''
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
<!--- Provide a general summary of the issue in the Title above -->
|
|
||||||
|
|
||||||
## Expected Behavior
|
|
||||||
<!--- Tell us how your feature should work -->
|
|
||||||
|
|
||||||
## Current Behavior
|
|
||||||
<!--- Explain the difference your feature will have from current behavior -->
|
|
||||||
|
|
||||||
## Possible Solution
|
|
||||||
<!--- Not obligatory, but suggest ideas on how to implement the addition or change -->
|
|
||||||
|
|
||||||
## Context
|
|
||||||
<!--- How has this issue affected you? What are you trying to accomplish? -->
|
|
||||||
<!--- Providing context helps us come up with a solution that is most useful in the real world -->
|
|
||||||
|
|
@ -0,0 +1,34 @@
|
||||||
|
name: 💡 Feature request
|
||||||
|
title: "[Feature]: "
|
||||||
|
description: Suggest an idea for this project
|
||||||
|
labels: "feature request"
|
||||||
|
body:
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Expected behavior
|
||||||
|
description: Tell us how your feature should work.
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Current behavior
|
||||||
|
description: Explain the difference your feature will have from current behavior.
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Possible solution
|
||||||
|
description: Tell us how it could be fixed at your glance.
|
||||||
|
validations:
|
||||||
|
required: false
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Context
|
||||||
|
description: >
|
||||||
|
How has this issue affected you? What are you trying to accomplish?
|
||||||
|
Providing context helps us come up with a solution that is most useful in the real world.
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Notes
|
||||||
|
description: >
|
||||||
|
Provide any extra details here.
|
||||||
|
|
@ -1,17 +1,13 @@
|
||||||
name: CI
|
name: CI
|
||||||
|
|
||||||
# Triggers the workflow on push or pull request events
|
# Triggers the workflow on push or pull request events
|
||||||
on:
|
on: [push, pull_request]
|
||||||
push:
|
|
||||||
branches: [ master ]
|
|
||||||
pull_request:
|
|
||||||
branches: [ master ]
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
bats-test:
|
bats-test:
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os: [ubuntu-20.04, ubuntu-18.04, ubuntu-16.04, macos-10.15]
|
os: [ubuntu-20.04, ubuntu-22.04, macos-12, macos-11]
|
||||||
|
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
|
|
||||||
|
|
@ -20,6 +16,9 @@ jobs:
|
||||||
- name: Install greadlink
|
- name: Install greadlink
|
||||||
if: startsWith(runner.os, 'macOS')
|
if: startsWith(runner.os, 'macOS')
|
||||||
run: brew install coreutils
|
run: brew install coreutils
|
||||||
|
- name: Install parallel
|
||||||
|
if: startsWith(runner.os, 'macOS')
|
||||||
|
run: brew install parallel
|
||||||
- name: Test code
|
- name: Test code
|
||||||
run: test/run
|
run: test/run
|
||||||
|
|
||||||
|
|
@ -45,15 +44,22 @@ jobs:
|
||||||
- name: Set up Go
|
- name: Set up Go
|
||||||
uses: actions/setup-go@v2
|
uses: actions/setup-go@v2
|
||||||
with:
|
with:
|
||||||
go-version: 1.14
|
go-version: 1.17
|
||||||
- name: Set up Python
|
- name: Set up Python
|
||||||
uses: actions/setup-python@v2
|
uses: actions/setup-python@v2
|
||||||
with:
|
with:
|
||||||
python-version: 3.8
|
python-version: 3.8
|
||||||
|
# - name: Update APT Package Lists
|
||||||
|
# run: sudo apt-get update
|
||||||
- name: Install shfmt
|
- name: Install shfmt
|
||||||
run: GO111MODULE=on go get mvdan.cc/sh/v3/cmd/shfmt
|
run: GO111MODULE=on go get mvdan.cc/sh/v3/cmd/shfmt
|
||||||
- name: Install shellcheck
|
- name: Install shellcheck
|
||||||
run: brew install shellcheck
|
env:
|
||||||
|
scversion: stable # Or latest, vxx, etc
|
||||||
|
run: |
|
||||||
|
wget -qO- "https://github.com/koalaman/shellcheck/releases/download/${scversion?}/shellcheck-${scversion?}.linux.x86_64.tar.xz" | tar -xJv "shellcheck-${scversion}/shellcheck"
|
||||||
|
sudo cp "shellcheck-${scversion}/shellcheck" /usr/bin/
|
||||||
|
shellcheck --version
|
||||||
- name: Install pre-commit
|
- name: Install pre-commit
|
||||||
run: python3 -m pip install -r test/lint-requirements.txt
|
run: python3 -m pip install -r test/lint-requirements.txt
|
||||||
- name: Run lint
|
- name: Run lint
|
||||||
|
|
|
||||||
|
|
@ -17,3 +17,8 @@ bats
|
||||||
enabled/*
|
enabled/*
|
||||||
/enabled
|
/enabled
|
||||||
tmp/
|
tmp/
|
||||||
|
|
||||||
|
# Do not save profiles
|
||||||
|
profiles/*
|
||||||
|
# apart from the default one
|
||||||
|
!profiles/default.bash_it
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ repos:
|
||||||
- id: mixed-line-ending
|
- id: mixed-line-ending
|
||||||
- id: check-added-large-files
|
- id: check-added-large-files
|
||||||
- repo: https://github.com/jumanjihouse/pre-commit-hooks
|
- repo: https://github.com/jumanjihouse/pre-commit-hooks
|
||||||
rev: 2.1.4
|
rev: 2.1.5
|
||||||
hooks:
|
hooks:
|
||||||
- id: git-check # Configure in .gitattributes
|
- id: git-check # Configure in .gitattributes
|
||||||
- id: shellcheck
|
- id: shellcheck
|
||||||
|
|
@ -43,3 +43,8 @@ repos:
|
||||||
language: system
|
language: system
|
||||||
files: "\\.bash$"
|
files: "\\.bash$"
|
||||||
types: [file]
|
types: [file]
|
||||||
|
- id: clean-files-txt
|
||||||
|
name: Check that clean_files.txt is sorted alphabetically.
|
||||||
|
entry: ./hooks/check-clean-files-txt.sh
|
||||||
|
language: system
|
||||||
|
files: clean_files.txt
|
||||||
|
|
|
||||||
|
|
@ -1,6 +0,0 @@
|
||||||
# We use colors and not assigned
|
|
||||||
disable=SC2154
|
|
||||||
# Hard to fix
|
|
||||||
disable=SC2155
|
|
||||||
# shellcheck is wrong on some
|
|
||||||
disable=SC2034
|
|
||||||
2
LICENSE
2
LICENSE
|
|
@ -1,6 +1,6 @@
|
||||||
MIT License
|
MIT License
|
||||||
|
|
||||||
Copyright (c) 2020 Bash-it
|
Copyright (c) 2020-2021 Bash-it
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'the silver searcher (ag) aliases'
|
about-alias 'the silver searcher (ag) aliases'
|
||||||
|
|
||||||
## Summary for args to less:
|
## Summary for args to less:
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'ansible abbreviations'
|
about-alias 'ansible abbreviations'
|
||||||
|
|
||||||
alias ans=ansible
|
alias ans=ansible
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/bash
|
# shellcheck shell=bash
|
||||||
#
|
#
|
||||||
# -binaryanomaly
|
# -binaryanomaly
|
||||||
|
|
||||||
|
|
@ -6,9 +6,8 @@ cite 'about-alias'
|
||||||
about-alias 'Apt and dpkg aliases for Ubuntu and Debian distros.'
|
about-alias 'Apt and dpkg aliases for Ubuntu and Debian distros.'
|
||||||
|
|
||||||
# set apt aliases
|
# set apt aliases
|
||||||
function _set_pkg_aliases()
|
function _set_pkg_aliases() {
|
||||||
{
|
if _command_exists apt; then
|
||||||
if [ -x $(which apt) ]; then
|
|
||||||
alias apts='apt-cache search'
|
alias apts='apt-cache search'
|
||||||
alias aptshow='apt-cache show'
|
alias aptshow='apt-cache show'
|
||||||
alias aptinst='sudo apt-get install -V'
|
alias aptinst='sudo apt-get install -V'
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'Atom.io editor abbreviations'
|
about-alias 'Atom.io editor abbreviations'
|
||||||
|
|
||||||
alias a='atom'
|
alias a='atom'
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite about-alias
|
# shellcheck shell=bash
|
||||||
about-alias 'Aliases for the bash-it command (these aliases are automatically included with the "general" aliases)'
|
about-alias 'Aliases for the bash-it command (these aliases are automatically included with the "general" aliases)'
|
||||||
|
|
||||||
# Common misspellings of bash-it
|
# Common misspellings of bash-it
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'puppet bolt aliases'
|
about-alias 'puppet bolt aliases'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'ruby bundler'
|
about-alias 'ruby bundler'
|
||||||
|
|
||||||
# Bundler Commands
|
# Bundler Commands
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'xclip shortcuts'
|
about-alias 'xclip shortcuts'
|
||||||
|
|
||||||
alias pbcopy="xclip -selection clipboard"
|
alias pbcopy="xclip -selection clipboard"
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'common composer abbreviations'
|
about-alias 'common composer abbreviations'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
|
||||||
|
|
@ -1,22 +1,19 @@
|
||||||
#!/bin/bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'Curl aliases for convenience.'
|
about-alias 'Curl aliases for convenience.'
|
||||||
|
|
||||||
# set apt aliases
|
# set apt aliases
|
||||||
function _set_pkg_aliases()
|
function _set_pkg_aliases() {
|
||||||
{
|
if _command_exists curl; then
|
||||||
if [ -x $(which curl) ]; then
|
|
||||||
# follow redirects
|
# follow redirects
|
||||||
alias cl='curl -L'
|
alias cl='curl -L'
|
||||||
# follow redirects, download as original name
|
# follow redirects, download as original name
|
||||||
alias clo='curl -L -O'
|
alias clo='curl -L -O'
|
||||||
# follow redirects, download as original name, continue
|
# follow redirects, download as original name, continue
|
||||||
alias cloc='curl -L -C - -O'
|
alias cloc='curl -L -C - -O'
|
||||||
# follow redirects, download as original name, continue, retry 5 times
|
# follow redirects, download as original name, continue, retry 5 times
|
||||||
alias clocr='curl -L -C - -O --retry 5'
|
alias clocr='curl -L -C - -O --retry 5'
|
||||||
# follow redirects, fetch banner
|
# follow redirects, fetch banner
|
||||||
alias clb='curl -L -I'
|
alias clb='curl -L -I'
|
||||||
# see only response headers from a get request
|
# see only response headers from a get request
|
||||||
alias clhead='curl -D - -so /dev/null'
|
alias clhead='curl -D - -so /dev/null'
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'dnf aliases for fedora 22+ distros'
|
about-alias 'dnf aliases for fedora 22+ distros'
|
||||||
|
|
||||||
alias dnfl="dnf list" # List packages
|
alias dnfl="dnf list" # List packages
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'docker-compose abbreviations'
|
about-alias 'docker-compose abbreviations'
|
||||||
|
|
||||||
alias dco="docker-compose"
|
alias dco="docker-compose"
|
||||||
|
|
@ -7,3 +7,4 @@ alias dco="docker-compose"
|
||||||
alias dcofresh="docker-compose-fresh"
|
alias dcofresh="docker-compose-fresh"
|
||||||
alias dcol="docker-compose logs -f --tail 100"
|
alias dcol="docker-compose logs -f --tail 100"
|
||||||
alias dcou="docker-compose up"
|
alias dcou="docker-compose up"
|
||||||
|
alias dcouns="dcou --no-start"
|
||||||
|
|
|
||||||
|
|
@ -1,32 +1,32 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'docker abbreviations'
|
about-alias 'docker abbreviations'
|
||||||
|
|
||||||
alias dk='docker'
|
alias dk='docker'
|
||||||
alias dklc='docker ps -l' # List last Docker container
|
alias dklc='docker ps -l' # List last Docker container
|
||||||
alias dklcid='docker ps -l -q' # List last Docker container ID
|
alias dklcid='docker ps -l -q' # List last Docker container ID
|
||||||
alias dklcip='docker inspect -f "{{.NetworkSettings.IPAddress}}" $(docker ps -l -q)' # Get IP of last Docker container
|
alias dklcip='docker inspect -f "{{.NetworkSettings.IPAddress}}" $(docker ps -l -q)' # Get IP of last Docker container
|
||||||
alias dkps='docker ps' # List running Docker containers
|
alias dkps='docker ps' # List running Docker containers
|
||||||
alias dkpsa='docker ps -a' # List all Docker containers
|
alias dkpsa='docker ps -a' # List all Docker containers
|
||||||
alias dki='docker images' # List Docker images
|
alias dki='docker images' # List Docker images
|
||||||
alias dkrmac='docker rm $(docker ps -a -q)' # Delete all Docker containers
|
alias dkrmac='docker rm $(docker ps -a -q)' # Delete all Docker containers
|
||||||
|
|
||||||
case $OSTYPE in
|
case $OSTYPE in
|
||||||
darwin*|*bsd*|*BSD*)
|
darwin* | *bsd* | *BSD*)
|
||||||
alias dkrmui='docker images -q -f dangling=true | xargs docker rmi' # Delete all untagged Docker images
|
alias dkrmui='docker images -q -f dangling=true | xargs docker rmi' # Delete all untagged Docker images
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
alias dkrmui='docker images -q -f dangling=true | xargs -r docker rmi' # Delete all untagged Docker images
|
alias dkrmui='docker images -q -f dangling=true | xargs -r docker rmi' # Delete all untagged Docker images
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
if [ ! -z "$(command ls "${BASH_IT}/enabled/"{[0-9][0-9][0-9]${BASH_IT_LOAD_PRIORITY_SEPARATOR}docker,docker}.plugin.bash 2>/dev/null | head -1)" ]; then
|
if _bash-it-component-item-is-enabled plugin docker; then
|
||||||
# Function aliases from docker plugin:
|
# Function aliases from docker plugin:
|
||||||
alias dkrmlc='docker-remove-most-recent-container' # Delete most recent (i.e., last) Docker container
|
alias dkrmlc='docker-remove-most-recent-container' # Delete most recent (i.e., last) Docker container
|
||||||
alias dkrmall='docker-remove-stale-assets' # Delete all untagged images and exited containers
|
alias dkrmall='docker-remove-stale-assets' # Delete all untagged images and exited containers
|
||||||
alias dkrmli='docker-remove-most-recent-image' # Delete most recent (i.e., last) Docker image
|
alias dkrmli='docker-remove-most-recent-image' # Delete most recent (i.e., last) Docker image
|
||||||
alias dkrmi='docker-remove-images' # Delete images for supplied IDs or all if no IDs are passed as arguments
|
alias dkrmi='docker-remove-images' # Delete images for supplied IDs or all if no IDs are passed as arguments
|
||||||
alias dkideps='docker-image-dependencies' # Output a graph of image dependencies using Graphiz
|
alias dkideps='docker-image-dependencies' # Output a graph of image dependencies using Graphiz
|
||||||
alias dkre='docker-runtime-environment' # List environmental variables of the supplied image ID
|
alias dkre='docker-runtime-environment' # List environmental variables of the supplied image ID
|
||||||
fi
|
fi
|
||||||
alias dkelc='docker exec -it $(dklcid) bash --login' # Enter last container (works with Docker 1.3 and above)
|
alias dkelc='docker exec -it $(dklcid) bash --login' # Enter last container (works with Docker 1.3 and above)
|
||||||
alias dkrmflast='docker rm -f $(dklcid)'
|
alias dkrmflast='docker rm -f $(dklcid)'
|
||||||
|
|
|
||||||
|
|
@ -1,16 +1,16 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'emacs editor'
|
about-alias 'emacs editor'
|
||||||
|
|
||||||
case $OSTYPE in
|
case $OSTYPE in
|
||||||
linux*)
|
linux*)
|
||||||
alias em='emacs'
|
alias em='emacs'
|
||||||
alias en='emacs -nw'
|
alias en='emacs -nw'
|
||||||
alias e='emacsclient -n'
|
alias e='emacsclient -n'
|
||||||
alias et='emacsclient -t'
|
alias et='emacsclient -t'
|
||||||
alias ed='emacs --daemon'
|
alias ed='emacs --daemon'
|
||||||
alias E='SUDO_EDITOR=emacsclient sudo -e'
|
alias E='SUDO_EDITOR=emacsclient sudo -e'
|
||||||
;;
|
;;
|
||||||
darwin*)
|
darwin*)
|
||||||
alias em='open -a emacs'
|
alias em='open -a emacs'
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,9 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'fuck/please to retry last command with sudo'
|
about-alias 'fuck/please to retry last command with sudo'
|
||||||
|
|
||||||
# Play nicely with 'thefuck' plugin
|
# Play nicely with 'thefuck' plugin
|
||||||
if ! _command_exists fuck ; then
|
if ! _command_exists fuck; then
|
||||||
alias fuck='sudo $(fc -ln -1)'
|
alias fuck='sudo $(fc -ln -1)'
|
||||||
fi
|
fi
|
||||||
alias please=fuck
|
alias please=fuck
|
||||||
alias plz=please
|
alias plz=please
|
||||||
|
|
|
||||||
|
|
@ -1,50 +1,45 @@
|
||||||
cite about-alias
|
# shellcheck shell=bash
|
||||||
about-alias 'general aliases'
|
about-alias 'general aliases'
|
||||||
|
|
||||||
if ls --color -d . &> /dev/null
|
if command ls --color -d . &> /dev/null; then
|
||||||
then
|
alias ls='ls --color=auto'
|
||||||
alias ls="ls --color=auto"
|
# BSD `ls` doesn't need an argument (`-G`) when `$CLICOLOR` is set.
|
||||||
elif ls -G -d . &> /dev/null
|
|
||||||
then
|
|
||||||
alias ls='ls -G' # Compact view, show colors
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# List directory contents
|
# List directory contents
|
||||||
alias sl=ls
|
alias sl=ls
|
||||||
alias la='ls -AF' # Compact view, show hidden
|
alias la='ls -AF' # Compact view, show hidden
|
||||||
alias ll='ls -al'
|
alias ll='ls -al'
|
||||||
alias l='ls -a'
|
alias l='ls -a'
|
||||||
alias l1='ls -1'
|
alias l1='ls -1'
|
||||||
|
alias lf='ls -F'
|
||||||
|
|
||||||
alias _="sudo"
|
alias _='sudo'
|
||||||
|
|
||||||
# Shortcuts to edit startup files
|
# Shortcuts to edit startup files
|
||||||
alias vbrc="vim ~/.bashrc"
|
alias vbrc='${VISUAL:-vim} ~/.bashrc'
|
||||||
alias vbpf="vim ~/.bash_profile"
|
alias vbpf='${VISUAL:-vim} ~/.bash_profile'
|
||||||
|
|
||||||
# colored grep
|
# colored grep
|
||||||
# Need to check an existing file for a pattern that will be found to ensure
|
# Need to check an existing file for a pattern that will be found to ensure
|
||||||
# that the check works when on an OS that supports the color option
|
# that the check works when on an OS that supports the color option
|
||||||
if grep --color=auto "a" "${BASH_IT}/"*.md &> /dev/null
|
if command grep --color=auto "a" "${BASH_IT?}"/*.md &> /dev/null; then
|
||||||
then
|
alias grep='grep --color=auto'
|
||||||
alias grep='grep --color=auto'
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if which gshuf &> /dev/null
|
if _command_exists gshuf; then
|
||||||
then
|
alias shuf=gshuf
|
||||||
alias shuf=gshuf
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
alias c='clear'
|
alias c='clear'
|
||||||
alias k='clear'
|
|
||||||
alias cls='clear'
|
alias cls='clear'
|
||||||
|
|
||||||
alias edit="$EDITOR"
|
alias edit='${EDITOR:-${ALTERNATE_EDITOR:-nano}}'
|
||||||
alias pager="$PAGER"
|
alias pager='${PAGER:=less}'
|
||||||
|
|
||||||
alias q='exit'
|
alias q='exit'
|
||||||
|
|
||||||
alias irc="${IRC_CLIENT:=irc}"
|
alias irc='${IRC_CLIENT:=irc}'
|
||||||
|
|
||||||
# Language aliases
|
# Language aliases
|
||||||
alias rb='ruby'
|
alias rb='ruby'
|
||||||
|
|
@ -65,9 +60,8 @@ alias -- -='cd -' # Go back
|
||||||
alias h='history'
|
alias h='history'
|
||||||
|
|
||||||
# Tree
|
# Tree
|
||||||
if [ ! -x "$(which tree 2>/dev/null)" ]
|
if ! _command_exists tree; then
|
||||||
then
|
alias tree="find . -print | sed -e 's;[^/]*/;|____;g;s;____|; |;g'"
|
||||||
alias tree="find . -print | sed -e 's;[^/]*/;|____;g;s;____|; |;g'"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Directory
|
# Directory
|
||||||
|
|
@ -75,21 +69,17 @@ alias md='mkdir -p'
|
||||||
alias rd='rmdir'
|
alias rd='rmdir'
|
||||||
|
|
||||||
# Shorten extract
|
# Shorten extract
|
||||||
alias xt="extract"
|
alias xt='extract'
|
||||||
|
|
||||||
# sudo editors
|
|
||||||
alias svim="sudo vim"
|
|
||||||
alias snano="sudo nano"
|
|
||||||
|
|
||||||
# Display whatever file is regular file or folder
|
# Display whatever file is regular file or folder
|
||||||
catt() {
|
function catt() {
|
||||||
for i in "$@"; do
|
for i in "$@"; do
|
||||||
if [ -d "$i" ]; then
|
if [[ -d "$i" ]]; then
|
||||||
ls "$i"
|
ls "$i"
|
||||||
else
|
else
|
||||||
cat "$i"
|
cat "$i"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
# The Bash-it aliases were moved to the `bash-it.aliases.bash` file. The intent of this
|
# The Bash-it aliases were moved to the `bash-it.aliases.bash` file. The intent of this
|
||||||
|
|
@ -98,5 +88,5 @@ catt() {
|
||||||
# aliases and enable just the ones for Bash-it explicitly:
|
# aliases and enable just the ones for Bash-it explicitly:
|
||||||
# bash-it disable alias general
|
# bash-it disable alias general
|
||||||
# bash-it enable alias bash-it
|
# bash-it enable alias bash-it
|
||||||
# shellcheck source=./bash-it.aliases.bash
|
# shellcheck source-path=SCRIPTDIR
|
||||||
source "$BASH_IT/aliases/available/bash-it.aliases.bash"
|
source "$BASH_IT/aliases/available/bash-it.aliases.bash"
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'common git abbreviations'
|
about-alias 'common git abbreviations'
|
||||||
|
|
||||||
alias g='git'
|
alias g='git'
|
||||||
|
|
@ -9,13 +8,18 @@ alias get='git'
|
||||||
alias ga='git add'
|
alias ga='git add'
|
||||||
alias gall='git add -A'
|
alias gall='git add -A'
|
||||||
alias gap='git add -p'
|
alias gap='git add -p'
|
||||||
|
alias gav='git add -v'
|
||||||
|
|
||||||
# branch
|
# branch
|
||||||
alias gb='git branch'
|
alias gb='git branch'
|
||||||
alias gbD='git branch -D'
|
alias gba='git branch --all'
|
||||||
alias gba='git branch -a'
|
|
||||||
alias gbd='git branch -d'
|
alias gbd='git branch -d'
|
||||||
alias gbm='git branch -m'
|
alias gbD='git branch -D'
|
||||||
|
alias gbl='git branch --list'
|
||||||
|
alias gbla='git branch --list --all'
|
||||||
|
alias gblr='git branch --list --remotes'
|
||||||
|
alias gbm='git branch --move'
|
||||||
|
alias gbr='git branch --remotes'
|
||||||
alias gbt='git branch --track'
|
alias gbt='git branch --track'
|
||||||
alias gdel='git branch -D'
|
alias gdel='git branch -D'
|
||||||
|
|
||||||
|
|
@ -37,8 +41,8 @@ alias gcb='git checkout -b'
|
||||||
alias gco='git checkout'
|
alias gco='git checkout'
|
||||||
alias gcob='git checkout -b'
|
alias gcob='git checkout -b'
|
||||||
alias gcobu='git checkout -b ${USER}/'
|
alias gcobu='git checkout -b ${USER}/'
|
||||||
alias gcom='git checkout master'
|
alias gcom='git checkout $(get_default_branch)'
|
||||||
alias gcpd='git checkout master; git pull; git branch -D'
|
alias gcpd='git checkout $(get_default_branch); git pull; git branch -D'
|
||||||
alias gct='git checkout --track'
|
alias gct='git checkout --track'
|
||||||
|
|
||||||
# clone
|
# clone
|
||||||
|
|
@ -64,13 +68,14 @@ alias gf='git fetch --all --prune'
|
||||||
alias gft='git fetch --all --prune --tags'
|
alias gft='git fetch --all --prune --tags'
|
||||||
alias gftv='git fetch --all --prune --tags --verbose'
|
alias gftv='git fetch --all --prune --tags --verbose'
|
||||||
alias gfv='git fetch --all --prune --verbose'
|
alias gfv='git fetch --all --prune --verbose'
|
||||||
alias gmu='git fetch origin -v; git fetch upstream -v; git merge upstream/master'
|
alias gmu='git fetch origin -v; git fetch upstream -v; git merge upstream/$(get_default_branch)'
|
||||||
alias gup='git fetch && git rebase'
|
alias gup='git fetch && git rebase'
|
||||||
|
|
||||||
# log
|
# log
|
||||||
alias gg='git log --graph --pretty=format:'\''%C(bold)%h%Creset%C(magenta)%d%Creset %s %C(yellow)<%an> %C(cyan)(%cr)%Creset'\'' --abbrev-commit --date=relative'
|
alias gg='git log --graph --pretty=format:'\''%C(bold)%h%Creset%C(magenta)%d%Creset %s %C(yellow)<%an> %C(cyan)(%cr)%Creset'\'' --abbrev-commit --date=relative'
|
||||||
alias ggf='git log --graph --date=short --pretty=format:'\''%C(auto)%h %Cgreen%an%Creset %Cblue%cd%Creset %C(auto)%d %s'\'''
|
alias ggf='git log --graph --date=short --pretty=format:'\''%C(auto)%h %Cgreen%an%Creset %Cblue%cd%Creset %C(auto)%d %s'\'''
|
||||||
alias ggs='gg --stat'
|
alias ggs='gg --stat'
|
||||||
|
alias ggup='git log --branches --not --remotes --no-walk --decorate --oneline' # FROM https://stackoverflow.com/questions/39220870/in-git-list-names-of-branches-with-unpushed-commits
|
||||||
alias gll='git log --graph --pretty=oneline --abbrev-commit'
|
alias gll='git log --graph --pretty=oneline --abbrev-commit'
|
||||||
alias gnew='git log HEAD@{1}..HEAD@{0}' # Show commits since last pull, see http://blogs.atlassian.com/2014/10/advanced-git-aliases/
|
alias gnew='git log HEAD@{1}..HEAD@{0}' # Show commits since last pull, see http://blogs.atlassian.com/2014/10/advanced-git-aliases/
|
||||||
alias gwc='git whatchanged'
|
alias gwc='git whatchanged'
|
||||||
|
|
@ -84,7 +89,7 @@ alias glsum='git diff --name-only --diff-filter=U' # Show unmerged (conflicted)
|
||||||
alias ggui='git gui'
|
alias ggui='git gui'
|
||||||
|
|
||||||
# home
|
# home
|
||||||
alias ghm='cd '\''$(git rev-parse --show-toplevel)'\''' # Git home
|
alias ghm='cd "$(git rev-parse --show-toplevel)"' # Git home
|
||||||
# appendage to ghm
|
# appendage to ghm
|
||||||
if ! _command_exists gh; then
|
if ! _command_exists gh; then
|
||||||
alias gh='ghm'
|
alias gh='ghm'
|
||||||
|
|
@ -104,7 +109,7 @@ alias gp='git push'
|
||||||
alias gpd='git push --delete'
|
alias gpd='git push --delete'
|
||||||
alias gpf='git push --force'
|
alias gpf='git push --force'
|
||||||
alias gpo='git push origin HEAD'
|
alias gpo='git push origin HEAD'
|
||||||
alias gpom='git push origin master'
|
alias gpom='git push origin $(get_default_branch)'
|
||||||
alias gpu='git push --set-upstream'
|
alias gpu='git push --set-upstream'
|
||||||
alias gpunch='git push --force-with-lease'
|
alias gpunch='git push --force-with-lease'
|
||||||
alias gpuo='git push --set-upstream origin'
|
alias gpuo='git push --set-upstream origin'
|
||||||
|
|
@ -112,7 +117,7 @@ alias gpuoc='git push --set-upstream origin $(git symbolic-ref --short HEAD)'
|
||||||
|
|
||||||
# pull
|
# pull
|
||||||
alias gl='git pull'
|
alias gl='git pull'
|
||||||
alias glum='git pull upstream master'
|
alias glum='git pull upstream $(get_default_branch)'
|
||||||
alias gpl='git pull'
|
alias gpl='git pull'
|
||||||
alias gpp='git pull && git push'
|
alias gpp='git pull && git push'
|
||||||
alias gpr='git pull --rebase'
|
alias gpr='git pull --rebase'
|
||||||
|
|
@ -127,9 +132,11 @@ alias grm='git rm'
|
||||||
|
|
||||||
# rebase
|
# rebase
|
||||||
alias grb='git rebase'
|
alias grb='git rebase'
|
||||||
alias grm='git rebase master'
|
alias grbc='git rebase --continue'
|
||||||
alias grmi='git rebase master -i'
|
alias grm='git rebase $(get_default_branch)'
|
||||||
alias gprom='git fetch origin master && git rebase origin/master && git update-ref refs/heads/master origin/master' # Rebase with latest remote master
|
alias grmi='git rebase $(get_default_branch) -i'
|
||||||
|
alias grma='GIT_SEQUENCE_EDITOR=: git rebase $(get_default_branch) -i --autosquash'
|
||||||
|
alias gprom='git fetch origin $(get_default_branch) && git rebase origin/$(get_default_branch) && git update-ref refs/heads/$(get_default_branch) origin/$(get_default_branch)' # Rebase with latest remote
|
||||||
|
|
||||||
# reset
|
# reset
|
||||||
alias gus='git reset HEAD'
|
alias gus='git reset HEAD'
|
||||||
|
|
@ -173,7 +180,7 @@ alias gsu='git submodule update --init --recursive'
|
||||||
# these aliases requires git v2.23+
|
# these aliases requires git v2.23+
|
||||||
alias gsw='git switch'
|
alias gsw='git switch'
|
||||||
alias gswc='git switch --create'
|
alias gswc='git switch --create'
|
||||||
alias gswm='git switch master'
|
alias gswm='git switch $(get_default_branch)'
|
||||||
alias gswt='git switch --track'
|
alias gswt='git switch --track'
|
||||||
|
|
||||||
# tag
|
# tag
|
||||||
|
|
@ -195,3 +202,11 @@ esac
|
||||||
function gdv() {
|
function gdv() {
|
||||||
git diff --ignore-all-space "$@" | vim -R -
|
git diff --ignore-all-space "$@" | vim -R -
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function get_default_branch() {
|
||||||
|
if git branch | grep -q '^. main\s*$'; then
|
||||||
|
echo main
|
||||||
|
else
|
||||||
|
echo master
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'common git-svn abbreviations'
|
about-alias 'common git-svn abbreviations'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'heroku task abbreviations'
|
about-alias 'heroku task abbreviations'
|
||||||
|
|
||||||
# heroku
|
# heroku
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'mercurial abbreviations'
|
about-alias 'mercurial abbreviations'
|
||||||
|
|
||||||
alias hs='hg status'
|
alias hs='hg status'
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
# Some aliases for Homebrew Cask
|
# shellcheck shell=bash
|
||||||
|
about-alias 'Some aliases for Homebrew Cask'
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'homebrew-cask abbreviations'
|
|
||||||
|
|
||||||
alias bcin='brew cask install'
|
alias bcin='brew cask install'
|
||||||
alias bcrm='brew cask uninstall'
|
alias bcrm='brew cask uninstall'
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
# Some aliases for Homebrew
|
# shellcheck shell=bash
|
||||||
|
about-alias 'Some aliases for Homebrew'
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'homebrew abbreviations'
|
|
||||||
|
|
||||||
alias bup='brew update && brew upgrade'
|
alias bup='brew update && brew upgrade'
|
||||||
alias bout='brew outdated'
|
alias bout='brew outdated'
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'homesick aliases'
|
about-alias 'homesick aliases'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
@ -19,6 +19,5 @@ alias sikpsh="homesick push dotfiles"
|
||||||
alias sikrc="homesick rc dotfiles"
|
alias sikrc="homesick rc dotfiles"
|
||||||
alias sikpth="homesick show_path dotfiles"
|
alias sikpth="homesick show_path dotfiles"
|
||||||
alias sikst="homesick status dotfiles"
|
alias sikst="homesick status dotfiles"
|
||||||
alias siktrk="homesick track $1 dotfiles"
|
|
||||||
alias sikulnk="homesick unlink dotfiles"
|
alias sikulnk="homesick unlink dotfiles"
|
||||||
alias sikv="homesick version"
|
alias sikv="homesick version"
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'jitsu task abbreviations'
|
about-alias 'jitsu task abbreviations'
|
||||||
|
|
||||||
# jitsu
|
# jitsu
|
||||||
|
|
|
||||||
|
|
@ -1,25 +1,16 @@
|
||||||
#!/bin/bash
|
# shellcheck shell=bash
|
||||||
#
|
|
||||||
# -binaryanomaly
|
|
||||||
|
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'kubectl aliases'
|
about-alias 'kubectl aliases'
|
||||||
|
|
||||||
function _set_pkg_aliases()
|
if _command_exists kubectl; then
|
||||||
{
|
alias kc='kubectl'
|
||||||
if _command_exists kubectl; then
|
alias kcgp='kubectl get pods'
|
||||||
alias kc='kubectl'
|
alias kcgd='kubectl get deployments'
|
||||||
alias kcgp='kubectl get pods'
|
alias kcgn='kubectl get nodes'
|
||||||
alias kcgd='kubectl get deployments'
|
alias kcdp='kubectl describe pod'
|
||||||
alias kcgn='kubectl get nodes'
|
alias kcdd='kubectl describe deployment'
|
||||||
alias kcdp='kubectl describe pod'
|
alias kcdn='kubectl describe node'
|
||||||
alias kcdd='kubectl describe deployment'
|
alias kcgpan='kubectl get pods --all-namespaces'
|
||||||
alias kcdn='kubectl describe node'
|
alias kcgdan='kubectl get deployments --all-namespaces'
|
||||||
alias kcgpan='kubectl get pods --all-namespaces'
|
# launches a disposable netshoot pod in the k8s cluster
|
||||||
alias kcgdan='kubectl get deployments --all-namespaces'
|
alias kcnetshoot='kubectl run netshoot-$(date +%s) --rm -i --tty --image nicolaka/netshoot -- /bin/bash'
|
||||||
# launches a disposable netshoot pod in the k8s cluster
|
fi
|
||||||
alias kcnetshoot='kubectl run --generator=run-pod/v1 netshoot-$(date +%s) --rm -i --tty --image nicolaka/netshoot -- /bin/bash'
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_set_pkg_aliases
|
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,9 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'laravel artisan abbreviations'
|
about-alias 'laravel artisan abbreviations'
|
||||||
|
|
||||||
# A list of useful laravel aliases
|
# A list of useful laravel aliases
|
||||||
|
|
||||||
alias laravel="${HOME}/.composer/vendor/bin/laravel"
|
alias laravel='${HOME?}/.composer/vendor/bin/laravel'
|
||||||
# asset
|
# asset
|
||||||
alias a:apub='php artisan asset:publish'
|
alias a:apub='php artisan asset:publish'
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'maven abbreviations'
|
about-alias 'maven abbreviations'
|
||||||
|
|
||||||
alias mci='mvn clean install'
|
alias mci='mvn clean install'
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,4 @@
|
||||||
#!/bin/bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'MSYS2 aliases'
|
about-alias 'MSYS2 aliases'
|
||||||
|
|
||||||
LS_COMMON="-hG"
|
LS_COMMON="-hG"
|
||||||
|
|
@ -9,7 +7,8 @@ LS_COMMON="$LS_COMMON -I NTUSER.DAT\* -I ntuser.dat\*"
|
||||||
|
|
||||||
# alias
|
# alias
|
||||||
# setup the main ls alias if we've established common args
|
# setup the main ls alias if we've established common args
|
||||||
test -n "$LS_COMMON" && alias ls="command ls $LS_COMMON"
|
alias ls='command ls ${LS_COMMON:-}'
|
||||||
alias ll="ls -l"
|
alias ll="ls -l"
|
||||||
alias la="ls -a"
|
alias la="ls -a"
|
||||||
alias lal="ll -a"
|
alias lal="ll -a"
|
||||||
|
alias lf="ls -F"
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'the Node.js environment aliases'
|
about-alias 'the Node.js environment aliases'
|
||||||
|
|
||||||
# alias to setup nodejs development environment
|
# alias to setup nodejs development environment
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'common npm abbreviations'
|
about-alias 'common npm abbreviations'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
@ -22,6 +22,7 @@ alias nud='npm update'
|
||||||
alias nr='npm run'
|
alias nr='npm run'
|
||||||
alias nls='npm list --depth=0 2>/dev/null'
|
alias nls='npm list --depth=0 2>/dev/null'
|
||||||
alias nlsg='npm list -g --depth=0 2>/dev/null'
|
alias nlsg='npm list -g --depth=0 2>/dev/null'
|
||||||
|
alias nt='npm test'
|
||||||
|
|
||||||
# npx
|
# npx
|
||||||
alias nx='npx'
|
alias nx='npx'
|
||||||
|
|
|
||||||
|
|
@ -1,27 +1,28 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'osx-specific aliases'
|
about-alias 'osx-specific aliases'
|
||||||
|
|
||||||
# Desktop Programs
|
# Desktop Programs
|
||||||
alias fireworks="open -a '/Applications/Adobe Fireworks CS3/Adobe Fireworks CS3.app'"
|
alias fireworks='open -a "/Applications/Adobe Fireworks CS3/Adobe Fireworks CS3.app"'
|
||||||
alias photoshop="open -a '/Applications/Adobe Photoshop CS3/Adobe Photoshop.app'"
|
alias photoshop='open -a "/Applications/Adobe Photoshop CS3/Adobe Photoshop.app"'
|
||||||
alias preview="open -a '$PREVIEW'"
|
alias preview='open -a "${PREVIEW?}"'
|
||||||
alias xcode="open -a '/Applications/XCode.app'"
|
alias xcode='open -a "/Applications/XCode.app"'
|
||||||
alias filemerge="open -a '/Developer/Applications/Utilities/FileMerge.app'"
|
alias filemerge='open -a "/Developer/Applications/Utilities/FileMerge.app"'
|
||||||
alias safari="open -a safari"
|
alias safari='open -a safari'
|
||||||
alias firefox="open -a firefox"
|
alias firefox='open -a firefox'
|
||||||
alias chrome="open -a google\ chrome"
|
alias chrome='open -a "Google Chrome"'
|
||||||
alias chromium="open -a chromium"
|
alias chromium='open -a chromium'
|
||||||
alias dashcode="open -a dashcode"
|
alias brave='open -a "Brave Browser"'
|
||||||
|
alias dashcode='open -a dashcode'
|
||||||
alias f='open -a Finder '
|
alias f='open -a Finder '
|
||||||
alias fh='open -a Finder .'
|
alias fh='open -a Finder .'
|
||||||
alias textedit='open -a TextEdit'
|
alias textedit='open -a TextEdit'
|
||||||
alias hex='open -a "Hex Fiend"'
|
alias hex='open -a "Hex Fiend"'
|
||||||
alias skype='open -a Skype'
|
alias skype='open -a Skype'
|
||||||
alias mou='open -a Mou'
|
alias mou='open -a Mou'
|
||||||
alias subl='open -a Sublime\ Text'
|
alias subl='open -a "Sublime Text"'
|
||||||
|
|
||||||
if [ -s /usr/bin/firefox ] ; then
|
if [[ -s /usr/bin/firefox ]]; then
|
||||||
unalias firefox
|
unalias firefox
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Requires growlnotify, which can be found in the Growl DMG under "Extras"
|
# Requires growlnotify, which can be found in the Growl DMG under "Extras"
|
||||||
|
|
@ -37,19 +38,20 @@ alias whotunes='lsof -r 2 -n -P -F n -c iTunes -a -i TCP@`hostname`:3689'
|
||||||
alias flush='dscacheutil -flushcache'
|
alias flush='dscacheutil -flushcache'
|
||||||
|
|
||||||
# Show/hide hidden files (for Mac OS X Mavericks)
|
# Show/hide hidden files (for Mac OS X Mavericks)
|
||||||
alias showhidden="defaults write com.apple.finder AppleShowAllFiles TRUE"
|
alias showhidden='defaults write com.apple.finder AppleShowAllFiles TRUE'
|
||||||
alias hidehidden="defaults write com.apple.finder AppleShowAllFiles FALSE"
|
alias hidehidden='defaults write com.apple.finder AppleShowAllFiles FALSE'
|
||||||
|
|
||||||
# From http://apple.stackexchange.com/questions/110343/copy-last-command-in-terminal
|
# From http://apple.stackexchange.com/questions/110343/copy-last-command-in-terminal
|
||||||
alias copyLastCmd='fc -ln -1 | awk '\''{$1=$1}1'\'' ORS='\'''\'' | pbcopy'
|
# shellcheck disable=SC2142 # The quoting confuses `shellcheck`...
|
||||||
|
alias copyLastCmd="fc -ln -1 | awk '{\$1=\$1}1' ORS='' | pbcopy"
|
||||||
|
|
||||||
# Use Finder's Quick Look on a file (^C or space to close)
|
# Use Finder's Quick Look on a file (^C or space to close)
|
||||||
alias ql='qlmanage -p 2>/dev/null'
|
alias ql='qlmanage -p 2>/dev/null'
|
||||||
|
|
||||||
# Mute/Unmute the system volume. Plays nice with all other volume settings.
|
# Mute/Unmute the system volume. Plays nice with all other volume settings.
|
||||||
alias mute="osascript -e 'set volume output muted true'"
|
alias mute='osascript -e "set volume output muted true"'
|
||||||
alias unmute="osascript -e 'set volume output muted false'"
|
alias unmute='osascript -e "set volume output muted false"'
|
||||||
|
|
||||||
# Pin to the tail of long commands for an audible alert after long processes
|
# Pin to the tail of long commands for an audible alert after long processes
|
||||||
## curl http://downloads.com/hugefile.zip; lmk
|
## curl http://downloads.com/hugefile.zip; lmk
|
||||||
alias lmk="say 'Process complete.'"
|
alias lmk='say "Process complete."'
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'phoenix abbreviations'
|
about-alias 'phoenix abbreviations'
|
||||||
|
|
||||||
# Phoenix Commands
|
# Phoenix Commands
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'puppet aliases'
|
about-alias 'puppet aliases'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'pyrocms abbreviations'
|
about-alias 'pyrocms abbreviations'
|
||||||
|
|
||||||
###
|
###
|
||||||
|
|
@ -7,146 +7,146 @@ about-alias 'pyrocms abbreviations'
|
||||||
###
|
###
|
||||||
|
|
||||||
# general
|
# general
|
||||||
alias a:cl="php artisan clear-compiled" # Remove the compiled class file
|
alias a:cl="php artisan clear-compiled" # Remove the compiled class file
|
||||||
alias a:d="php artisan down" # Put the application into maintenance mode
|
alias a:d="php artisan down" # Put the application into maintenance mode
|
||||||
alias a:e="php artisan env" # Display the current framework environment
|
alias a:e="php artisan env" # Display the current framework environment
|
||||||
alias a:h="php artisan help" # Displays help for a command
|
alias a:h="php artisan help" # Displays help for a command
|
||||||
alias a:i="php artisan install" # Install the Streams Platform.
|
alias a:i="php artisan install" # Install the Streams Platform.
|
||||||
alias a:ls="php artisan list" # Lists commands
|
alias a:ls="php artisan list" # Lists commands
|
||||||
alias a:mg="php artisan migrate" # Run the database migrations
|
alias a:mg="php artisan migrate" # Run the database migrations
|
||||||
alias a:op="php artisan optimize" # Optimize the framework for better performance (deprecated)
|
alias a:op="php artisan optimize" # Optimize the framework for better performance (deprecated)
|
||||||
alias a:pr="php artisan preset" # Swap the front-end scaffolding for the application
|
alias a:pr="php artisan preset" # Swap the front-end scaffolding for the application
|
||||||
alias a:s="php artisan serve" # Serve the application on the PHP development server
|
alias a:s="php artisan serve" # Serve the application on the PHP development server
|
||||||
alias a:u="php artisan up" # Bring the application out of maintenance mode
|
alias a:u="php artisan up" # Bring the application out of maintenance mode
|
||||||
|
|
||||||
# addon
|
# addon
|
||||||
alias a:ad:i="php artisan addon:install" # Install an addon.
|
alias a:ad:i="php artisan addon:install" # Install an addon.
|
||||||
alias a:ad:p="php artisan addon:publish" # Publish an the configuration and translations for an addon.
|
alias a:ad:p="php artisan addon:publish" # Publish an the configuration and translations for an addon.
|
||||||
alias a:ad:r="php artisan addon:reinstall" # Reinstall an addon.
|
alias a:ad:r="php artisan addon:reinstall" # Reinstall an addon.
|
||||||
alias a:ad:u="php artisan addon:uninstall" # Uninstall an addon.
|
alias a:ad:u="php artisan addon:uninstall" # Uninstall an addon.
|
||||||
|
|
||||||
# app
|
# app
|
||||||
alias a:ap:n="php artisan app:name" # Set the application namespace
|
alias a:ap:n="php artisan app:name" # Set the application namespace
|
||||||
alias a:ap:p="php artisan app:publish" # Publish general application override files.
|
alias a:ap:p="php artisan app:publish" # Publish general application override files.
|
||||||
|
|
||||||
# assets
|
# assets
|
||||||
alias a:as:cl="php artisan assets:clear" # Clear compiled public assets.
|
alias a:as:cl="php artisan assets:clear" # Clear compiled public assets.
|
||||||
|
|
||||||
# auth
|
# auth
|
||||||
alias a:au:clrs="php artisan auth:clear-resets" # Flush expired password reset tokens
|
alias a:au:clrs="php artisan auth:clear-resets" # Flush expired password reset tokens
|
||||||
|
|
||||||
# cache
|
# cache
|
||||||
alias a:ca:cl="php artisan cache:clear" # Flush the application cache
|
alias a:ca:cl="php artisan cache:clear" # Flush the application cache
|
||||||
alias a:ca:f="php artisan cache:forget" # Remove an item from the cache
|
alias a:ca:f="php artisan cache:forget" # Remove an item from the cache
|
||||||
alias a:ca:t="php artisan cache:table" # Create a migration for the cache database table
|
alias a:ca:t="php artisan cache:table" # Create a migration for the cache database table
|
||||||
|
|
||||||
# config
|
# config
|
||||||
alias a:co:ca="php artisan config:cache" # Create a cache file for faster configuration loading
|
alias a:co:ca="php artisan config:cache" # Create a cache file for faster configuration loading
|
||||||
alias a:co:cl="php artisan config:clear" # Remove the configuration cache file
|
alias a:co:cl="php artisan config:clear" # Remove the configuration cache file
|
||||||
|
|
||||||
# db
|
# db
|
||||||
alias a:db:s="php artisan db:seed" # Seed the database with records
|
alias a:db:s="php artisan db:seed" # Seed the database with records
|
||||||
|
|
||||||
# env
|
# env
|
||||||
alias a:en:s="php artisan env:set" # Set an environmental value.
|
alias a:en:s="php artisan env:set" # Set an environmental value.
|
||||||
|
|
||||||
# event
|
# event
|
||||||
alias a:ev:g="php artisan event:generate" # Generate the missing events and listeners based on registration
|
alias a:ev:g="php artisan event:generate" # Generate the missing events and listeners based on registration
|
||||||
|
|
||||||
# extension
|
# extension
|
||||||
alias a:ex:i="php artisan extension:install" # Install a extension.
|
alias a:ex:i="php artisan extension:install" # Install a extension.
|
||||||
alias a:ex:r="php artisan extension:reinstall" # Reinstall a extension.
|
alias a:ex:r="php artisan extension:reinstall" # Reinstall a extension.
|
||||||
alias a:ex:u="php artisan extension:uninstall" # Uninstall a extension.
|
alias a:ex:u="php artisan extension:uninstall" # Uninstall a extension.
|
||||||
|
|
||||||
# files
|
# files
|
||||||
alias a:fi:cl="php artisan files:clean" # Clean missing files from the files table.
|
alias a:fi:cl="php artisan files:clean" # Clean missing files from the files table.
|
||||||
|
|
||||||
# key
|
# key
|
||||||
alias a:ke:g="php artisan key:generate" # Set the application key
|
alias a:ke:g="php artisan key:generate" # Set the application key
|
||||||
|
|
||||||
# make
|
# make
|
||||||
alias a:mk:ad="php artisan make:addon" # Create a new addon.
|
alias a:mk:ad="php artisan make:addon" # Create a new addon.
|
||||||
alias a:mk:au="php artisan make:auth" # Scaffold basic login and registration views and routes
|
alias a:mk:au="php artisan make:auth" # Scaffold basic login and registration views and routes
|
||||||
alias a:mk:cm="php artisan make:command" # Create a new Artisan command
|
alias a:mk:cm="php artisan make:command" # Create a new Artisan command
|
||||||
alias a:mk:ct="php artisan make:controller" # Create a new controller class
|
alias a:mk:ct="php artisan make:controller" # Create a new controller class
|
||||||
alias a:mk:ev="php artisan make:event" # Create a new event class
|
alias a:mk:ev="php artisan make:event" # Create a new event class
|
||||||
alias a:mk:fa="php artisan make:factory" # Create a new model factory
|
alias a:mk:fa="php artisan make:factory" # Create a new model factory
|
||||||
alias a:mk:j="php artisan make:job" # Create a new job class
|
alias a:mk:j="php artisan make:job" # Create a new job class
|
||||||
alias a:mk:li="php artisan make:listener" # Create a new event listener class
|
alias a:mk:li="php artisan make:listener" # Create a new event listener class
|
||||||
alias a:mk:ma="php artisan make:mail" # Create a new email class
|
alias a:mk:ma="php artisan make:mail" # Create a new email class
|
||||||
alias a:mk:mw="php artisan make:middleware" # Create a new middleware class
|
alias a:mk:mw="php artisan make:middleware" # Create a new middleware class
|
||||||
alias a:mk:mg="php artisan make:migration" # Create a new migration file
|
alias a:mk:mg="php artisan make:migration" # Create a new migration file
|
||||||
alias a:mk:md="php artisan make:model" # Create a new Eloquent model class
|
alias a:mk:md="php artisan make:model" # Create a new Eloquent model class
|
||||||
alias a:mk:no="php artisan make:notification" # Create a new notification class
|
alias a:mk:no="php artisan make:notification" # Create a new notification class
|
||||||
alias a:mk:po="php artisan make:policy" # Create a new policy class
|
alias a:mk:po="php artisan make:policy" # Create a new policy class
|
||||||
alias a:mk:pr="php artisan make:provider" # Create a new service provider class
|
alias a:mk:pr="php artisan make:provider" # Create a new service provider class
|
||||||
alias a:mk:rq="php artisan make:request" # Create a new form request class
|
alias a:mk:rq="php artisan make:request" # Create a new form request class
|
||||||
alias a:mk:rs="php artisan make:resource" # Create a new resource
|
alias a:mk:rs="php artisan make:resource" # Create a new resource
|
||||||
alias a:mk:rl="php artisan make:rule" # Create a new validation rule
|
alias a:mk:rl="php artisan make:rule" # Create a new validation rule
|
||||||
alias a:mk:sd="php artisan make:seeder" # Create a new seeder class
|
alias a:mk:sd="php artisan make:seeder" # Create a new seeder class
|
||||||
alias a:mk:st="php artisan make:stream" # Make a streams entity namespace.
|
alias a:mk:st="php artisan make:stream" # Make a streams entity namespace.
|
||||||
alias a:mk:ts="php artisan make:test" # Create a new test class
|
alias a:mk:ts="php artisan make:test" # Create a new test class
|
||||||
|
|
||||||
# migrate
|
# migrate
|
||||||
alias a:mg:fr="php artisan migrate:fresh" # Drop all tables and re-run all migrations
|
alias a:mg:fr="php artisan migrate:fresh" # Drop all tables and re-run all migrations
|
||||||
alias a:mg:i="php artisan migrate:install" # Create the migration repository
|
alias a:mg:i="php artisan migrate:install" # Create the migration repository
|
||||||
alias a:mg:rf="php artisan migrate:refresh" # Reset and re-run all migrations
|
alias a:mg:rf="php artisan migrate:refresh" # Reset and re-run all migrations
|
||||||
alias a:mg:rs="php artisan migrate:reset" # Rollback all database migrations
|
alias a:mg:rs="php artisan migrate:reset" # Rollback all database migrations
|
||||||
alias a:mg:rl="php artisan migrate:rollback" # Rollback the last database migration
|
alias a:mg:rl="php artisan migrate:rollback" # Rollback the last database migration
|
||||||
alias a:mg:st="php artisan migrate:status" # Show the status of each migration
|
alias a:mg:st="php artisan migrate:status" # Show the status of each migration
|
||||||
|
|
||||||
# module
|
# module
|
||||||
alias a:mo:i="php artisan module:install" # Install a module.
|
alias a:mo:i="php artisan module:install" # Install a module.
|
||||||
alias a:mo:r="php artisan module:reinstall" # Reinstall a module.
|
alias a:mo:r="php artisan module:reinstall" # Reinstall a module.
|
||||||
alias a:mo:u="php artisan module:uninstall" # Uninstall a module.
|
alias a:mo:u="php artisan module:uninstall" # Uninstall a module.
|
||||||
|
|
||||||
# notifications
|
# notifications
|
||||||
alias a:no:tb="php artisan notifications:table" # Create a migration for the notifications table
|
alias a:no:tb="php artisan notifications:table" # Create a migration for the notifications table
|
||||||
|
|
||||||
# package
|
# package
|
||||||
alias a:pk:d="php artisan package:discover" # Rebuild the cached package manifest
|
alias a:pk:d="php artisan package:discover" # Rebuild the cached package manifest
|
||||||
|
|
||||||
# queue
|
# queue
|
||||||
alias a:qu:fa="php artisan queue:failed" # List all of the failed queue jobs
|
alias a:qu:fa="php artisan queue:failed" # List all of the failed queue jobs
|
||||||
alias a:qu:ft="php artisan queue:failed-table" # Create a migration for the failed queue jobs database table
|
alias a:qu:ft="php artisan queue:failed-table" # Create a migration for the failed queue jobs database table
|
||||||
alias a:qu:fl="php artisan queue:flush" # Flush all of the failed queue jobs
|
alias a:qu:fl="php artisan queue:flush" # Flush all of the failed queue jobs
|
||||||
alias a:qu:fg="php artisan queue:forget" # Delete a failed queue job
|
alias a:qu:fg="php artisan queue:forget" # Delete a failed queue job
|
||||||
alias a:qu:li="php artisan queue:listen" # Listen to a given queue
|
alias a:qu:li="php artisan queue:listen" # Listen to a given queue
|
||||||
alias a:qu:rs="php artisan queue:restart" # Restart queue worker daemons after their current job
|
alias a:qu:rs="php artisan queue:restart" # Restart queue worker daemons after their current job
|
||||||
alias a:qu:rt="php artisan queue:retry" # Retry a failed queue job
|
alias a:qu:rt="php artisan queue:retry" # Retry a failed queue job
|
||||||
alias a:qu:tb="php artisan queue:table" # Create a migration for the queue jobs database table
|
alias a:qu:tb="php artisan queue:table" # Create a migration for the queue jobs database table
|
||||||
alias a:qu:w="php artisan queue:work" # Start processing jobs on the queue as a daemon
|
alias a:qu:w="php artisan queue:work" # Start processing jobs on the queue as a daemon
|
||||||
|
|
||||||
# route
|
# route
|
||||||
alias a:ro:ca="php artisan route:cache" # Create a route cache file for faster route registration
|
alias a:ro:ca="php artisan route:cache" # Create a route cache file for faster route registration
|
||||||
alias a:ro:cl="php artisan route:clear" # Remove the route cache file
|
alias a:ro:cl="php artisan route:clear" # Remove the route cache file
|
||||||
alias a:ro:ls="php artisan route:list" # List all registered routes
|
alias a:ro:ls="php artisan route:list" # List all registered routes
|
||||||
|
|
||||||
# schedule
|
# schedule
|
||||||
alias a:sc:r="php artisan schedule:run" # Run the scheduled commands
|
alias a:sc:r="php artisan schedule:run" # Run the scheduled commands
|
||||||
|
|
||||||
# scout
|
# scout
|
||||||
alias a:su:fl="php artisan scout:flush" # Flush all of the model's records from the index
|
alias a:su:fl="php artisan scout:flush" # Flush all of the model's records from the index
|
||||||
alias a:su:im="php artisan scout:import" # Import the given model into the search index
|
alias a:su:im="php artisan scout:import" # Import the given model into the search index
|
||||||
|
|
||||||
# session
|
# session
|
||||||
alias a:se:tb="php artisan session:table" # Create a migration for the session database table
|
alias a:se:tb="php artisan session:table" # Create a migration for the session database table
|
||||||
|
|
||||||
# storage
|
# storage
|
||||||
alias a:sg:l="php artisan storage:link" # Create a symbolic link from "public/storage" to "storage/app/public"
|
alias a:sg:l="php artisan storage:link" # Create a symbolic link from "public/storage" to "storage/app/public"
|
||||||
|
|
||||||
# streams
|
# streams
|
||||||
alias a:st:cl="php artisan streams:cleanup" # Cleanup streams entry models.
|
alias a:st:cl="php artisan streams:cleanup" # Cleanup streams entry models.
|
||||||
alias a:st:co="php artisan streams:compile" # Compile streams entry models.
|
alias a:st:co="php artisan streams:compile" # Compile streams entry models.
|
||||||
alias a:st:d="php artisan streams:destroy" # Destroy a namespace.
|
alias a:st:d="php artisan streams:destroy" # Destroy a namespace.
|
||||||
alias a:st:p="php artisan streams:publish" # Publish configuration and translations for streams.
|
alias a:st:p="php artisan streams:publish" # Publish configuration and translations for streams.
|
||||||
alias a:st:r="php artisan streams:refresh" # Refresh streams generated components.
|
alias a:st:r="php artisan streams:refresh" # Refresh streams generated components.
|
||||||
|
|
||||||
# tntsearch
|
# tntsearch
|
||||||
alias a:tn:im="php artisan tntsearch:import" # Import the given model into the search index
|
alias a:tn:im="php artisan tntsearch:import" # Import the given model into the search index
|
||||||
|
|
||||||
# vendor
|
# vendor
|
||||||
alias a:ve:p="php artisan vendor:publish" # Publish any publishable assets from vendor packages
|
alias a:ve:p="php artisan vendor:publish" # Publish any publishable assets from vendor packages
|
||||||
|
|
||||||
# view
|
# view
|
||||||
alias a:vi:cl="php artisan view:clear" # Clear all compiled view files
|
alias a:vi:cl="php artisan view:clear" # Clear all compiled view files
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'rails abbreviations'
|
about-alias 'rails abbreviations'
|
||||||
|
|
||||||
# Rails Commands
|
# Rails Commands
|
||||||
|
|
@ -14,9 +14,9 @@ alias rd='rails destroy'
|
||||||
alias dbm='rake db:migrate'
|
alias dbm='rake db:migrate'
|
||||||
|
|
||||||
alias ss='script/server'
|
alias ss='script/server'
|
||||||
alias ts="thin start" # thin server
|
alias ts="thin start" # thin server
|
||||||
alias sc='script/console'
|
alias sc='script/console'
|
||||||
alias restartapp='touch tmp/restart.txt'
|
alias restartapp='touch tmp/restart.txt'
|
||||||
alias restart='touch tmp/restart.txt' # restart passenger
|
alias restart='touch tmp/restart.txt' # restart passenger
|
||||||
alias devlog='tail -f log/development.log'
|
alias devlog='tail -f log/development.log'
|
||||||
alias taild='tail -f log/development.log' # tail dev log
|
alias taild='tail -f log/development.log' # tail dev log
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'common svn abbreviations'
|
about-alias 'common svn abbreviations'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
|
||||||
|
|
@ -1,15 +1,22 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'systemd service'
|
about-alias 'systemd service'
|
||||||
|
|
||||||
case $OSTYPE in
|
case $OSTYPE in
|
||||||
linux*)
|
linux*)
|
||||||
alias sc='systemctl'
|
# Improve aliases by bringing the common root `sc|scd` + `sre` for action + `u` for user
|
||||||
alias scr='systemctl daemon-reload'
|
alias sc='systemctl'
|
||||||
alias scu='systemctl --user'
|
alias scu='systemctl --user'
|
||||||
alias scur='systemctl --user daemon-reload'
|
alias scdr='systemctl daemon-reload'
|
||||||
alias sce='systemctl stop'
|
alias scdru='systemctl --user daemon-reload'
|
||||||
alias scue='systemctl --user stop'
|
alias scr='systemctl restart'
|
||||||
alias scs='systemctl start'
|
alias scru='systemctl --user restart'
|
||||||
alias scus='systemctl --user start'
|
alias sce='systemctl stop'
|
||||||
;;
|
alias sceu='systemctl --user stop'
|
||||||
|
alias scs='systemctl start'
|
||||||
|
alias scsu='systemctl --user start'
|
||||||
|
# Keeping previous aliases for a non-breaking change.
|
||||||
|
alias scue='sceu'
|
||||||
|
alias scus='scsu'
|
||||||
|
alias scur='scdru'
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,9 @@
|
||||||
# Aliases for Terraform and Terragrunt
|
# shellcheck shell=bash
|
||||||
|
about-alias 'Aliases for Terraform and Terragrunt'
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'Terraform abbreviations'
|
|
||||||
|
|
||||||
alias tf='terraform'
|
alias tf='terraform'
|
||||||
|
alias tfi='tf init'
|
||||||
alias tfv='terraform validate'
|
alias tfv='terraform validate'
|
||||||
alias tfp='terraform plan'
|
alias tfp='terraform plan'
|
||||||
alias tfa='terraform apply'
|
alias tfa='terraform apply'
|
||||||
alias tfd='terraform destory'
|
alias tfd='terraform destroy'
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
# Aliases for Terraform and Terragrunt
|
# shellcheck shell=bash
|
||||||
|
about-alias 'Aliases for Terraform and Terragrunt'
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'Terragrunt abbreviations'
|
|
||||||
|
|
||||||
alias tg='terragrunt'
|
alias tg='terragrunt'
|
||||||
alias tgv='terragrunt validate'
|
alias tgv='terragrunt validate'
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,10 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'textmate abbreviations'
|
about-alias 'textmate abbreviations'
|
||||||
|
|
||||||
case $OSTYPE in
|
case $OSTYPE in
|
||||||
darwin*)
|
darwin*)
|
||||||
# Textmate
|
# Textmate
|
||||||
alias e='mate . &'
|
alias e='mate . &'
|
||||||
alias et='mate app config db lib public script test spec config.ru Gemfile Rakefile README &'
|
alias et='mate app config db lib public script test spec config.ru Gemfile Rakefile README &'
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'Tmux terminal multiplexer'
|
about-alias 'Tmux terminal multiplexer'
|
||||||
|
|
||||||
alias txl='tmux ls'
|
alias txl='tmux ls'
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'todo.txt-cli abbreviations'
|
about-alias 'todo.txt-cli abbreviations'
|
||||||
|
|
||||||
alias tls="$TODO ls"
|
alias tls='"${TODO?}" ls'
|
||||||
alias ta="$TODO a"
|
alias ta='"${TODO?}" a'
|
||||||
alias trm="$TODO rm"
|
alias trm='"${TODO?}" rm'
|
||||||
alias tdo="$TODO do"
|
alias tdo='"${TODO?}" do'
|
||||||
alias tpri="$TODO pri"
|
alias tpri='"${TODO?}" pri'
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,11 @@
|
||||||
cite 'uuid-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'uuidgen aliases'
|
about-alias 'uuidgen aliases'
|
||||||
|
|
||||||
if _command_exists uuid; then # Linux
|
if _command_exists uuid; then # Linux
|
||||||
alias uuidu="uuid | tr '[:lower:]' '[:upper:]'"
|
alias uuidu="uuid | tr '[:lower:]' '[:upper:]'"
|
||||||
alias uuidl=uuid
|
alias uuidl=uuid
|
||||||
elif _command_exists uuidgen; then # macOS/BSD
|
elif _command_exists uuidgen; then # macOS/BSD
|
||||||
alias uuidu="uuidgen"
|
alias uuidu="uuidgen"
|
||||||
alias uuid="uuidgen | tr '[:upper:]' '[:lower:]'" # because upper case is like YELLING
|
alias uuid="uuidgen | tr '[:upper:]' '[:lower:]'" # because upper case is like YELLING
|
||||||
alias uuidl=uuid
|
alias uuidl=uuid
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'vagrant aliases'
|
about-alias 'vagrant aliases'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'vault aliases'
|
about-alias 'vault aliases'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
|
||||||
|
|
@ -1,25 +1,14 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
cite 'about-alias'
|
|
||||||
about-alias 'vim abbreviations'
|
about-alias 'vim abbreviations'
|
||||||
|
|
||||||
VIM=$(command -v vim)
|
_command_exists vim || return
|
||||||
GVIM=$(command -v gvim)
|
|
||||||
MVIM=$(command -v mvim)
|
|
||||||
|
|
||||||
if [[ -n $VIM ]]; then
|
alias v='vim'
|
||||||
alias v='$VIM'
|
# open the vim help in fullscreen incorporated from
|
||||||
# open the vim help in fullscreen incorporated from
|
# https://stackoverflow.com/a/4687513
|
||||||
# https://stackoverflow.com/a/4687513
|
alias vimh='vim -c ":h | only"'
|
||||||
alias vimh='${VIM} -c ":h | only"'
|
|
||||||
fi
|
|
||||||
|
|
||||||
# open vim in new tab is taken from
|
# open vim in new tab is taken from
|
||||||
# http://stackoverflow.com/questions/936501/let-gvim-always-run-a-single-instancek
|
# http://stackoverflow.com/questions/936501/let-gvim-always-run-a-single-instancek
|
||||||
case $OSTYPE in
|
_command_exists mvim && function mvimt { command mvim --remote-tab-silent "$@" || command mvim "$@"; }
|
||||||
darwin*)
|
_command_exists gvim && function gvimt { command gvim --remote-tab-silent "$@" || command gvim "$@"; }
|
||||||
[[ -n $MVIM ]] && function mvimt { command mvim --remote-tab-silent "$@" || command mvim "$@"; }
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
[[ -n $GVIM ]] && function gvimt { command gvim --remote-tab-silent "$@" || command gvim "$@"; }
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'yarn package manager aliases'
|
about-alias 'yarn package manager aliases'
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
|
|
||||||
163
bash_it.sh
163
bash_it.sh
|
|
@ -1,159 +1,110 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
# shellcheck source-path=SCRIPTDIR/lib source-path=SCRIPTDIR/scripts
|
||||||
|
# shellcheck disable=SC2034
|
||||||
|
#
|
||||||
# Initialize Bash It
|
# Initialize Bash It
|
||||||
BASH_IT_LOG_PREFIX="core: main: "
|
BASH_IT_LOG_PREFIX="core: main: "
|
||||||
|
: "${BASH_IT:=${BASH_SOURCE%/*}}"
|
||||||
# Only set $BASH_IT if it's not already set
|
: "${BASH_IT_CUSTOM:=${BASH_IT}/custom}"
|
||||||
if [ -z "$BASH_IT" ]; then
|
: "${CUSTOM_THEME_DIR:="${BASH_IT_CUSTOM}/themes"}"
|
||||||
# Setting $BASH to maintain backwards compatibility
|
: "${BASH_IT_BASHRC:=${BASH_SOURCE[${#BASH_SOURCE[@]} - 1]}}"
|
||||||
export BASH_IT=$BASH
|
|
||||||
BASH="$(bash -c 'echo $BASH')"
|
|
||||||
export BASH
|
|
||||||
BASH_IT_OLD_BASH_SETUP=true
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Load composure first, so we support function metadata
|
# Load composure first, so we support function metadata
|
||||||
# shellcheck disable=SC1090
|
# shellcheck source-path=SCRIPTDIR/vendor/github.com/erichs/composure
|
||||||
source "${BASH_IT}"/vendor/github.com/erichs/composure/composure.sh
|
source "${BASH_IT}/vendor/github.com/erichs/composure/composure.sh"
|
||||||
|
|
||||||
# We need to load logging module first as well in order to be able to log
|
|
||||||
# shellcheck source=./lib/log.bash
|
|
||||||
source "${BASH_IT}/lib/log.bash"
|
|
||||||
|
|
||||||
# We can only log it now
|
|
||||||
[ -z "$BASH_IT_OLD_BASH_SETUP" ] || _log_warning "BASH_IT variable not initialized, please upgrade your bash-it version and reinstall it!"
|
|
||||||
|
|
||||||
# For backwards compatibility, look in old BASH_THEME location
|
|
||||||
if [ -z "$BASH_IT_THEME" ]; then
|
|
||||||
_log_warning "BASH_IT_THEME variable not initialized, please upgrade your bash-it version and reinstall it!"
|
|
||||||
export BASH_IT_THEME="$BASH_THEME"
|
|
||||||
unset BASH_THEME
|
|
||||||
fi
|
|
||||||
|
|
||||||
# support 'plumbing' metadata
|
# support 'plumbing' metadata
|
||||||
cite _about _param _example _group _author _version
|
cite _about _param _example _group _author _version
|
||||||
cite about-alias about-plugin about-completion
|
cite about-alias about-plugin about-completion
|
||||||
|
|
||||||
|
# Declare our end-of-main finishing hook, but don't use `declare`/`typeset`
|
||||||
|
_bash_it_library_finalize_hook=()
|
||||||
|
|
||||||
|
# We need to load logging module early in order to be able to log
|
||||||
|
source "${BASH_IT}/lib/log.bash"
|
||||||
|
|
||||||
# libraries, but skip appearance (themes) for now
|
# libraries, but skip appearance (themes) for now
|
||||||
_log_debug "Loading libraries(except appearance)..."
|
_log_debug "Loading libraries(except appearance)..."
|
||||||
LIB="${BASH_IT}/lib/*.bash"
|
|
||||||
APPEARANCE_LIB="${BASH_IT}/lib/appearance.bash"
|
APPEARANCE_LIB="${BASH_IT}/lib/appearance.bash"
|
||||||
for _bash_it_config_file in $LIB; do
|
for _bash_it_main_file_lib in "${BASH_IT}/lib"/*.bash; do
|
||||||
if [ "$_bash_it_config_file" != "$APPEARANCE_LIB" ]; then
|
[[ "$_bash_it_main_file_lib" == "$APPEARANCE_LIB" ]] && continue
|
||||||
filename=${_bash_it_config_file##*/}
|
_bash-it-log-prefix-by-path "${_bash_it_main_file_lib}"
|
||||||
filename=${filename%.bash}
|
_log_debug "Loading library file..."
|
||||||
BASH_IT_LOG_PREFIX="lib: ${filename}: "
|
|
||||||
_log_debug "Loading library file..."
|
|
||||||
# shellcheck disable=SC1090
|
|
||||||
source "$_bash_it_config_file"
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
# Load vendors
|
|
||||||
BASH_IT_LOG_PREFIX="vendor: "
|
|
||||||
for _bash_it_vendor_init in "${BASH_IT}"/vendor/init.d/*.bash; do
|
|
||||||
_log_debug "Loading \"$(basename "${_bash_it_vendor_init}" .bash)\"..."
|
|
||||||
# shellcheck disable=SC1090
|
# shellcheck disable=SC1090
|
||||||
source "${_bash_it_vendor_init}"
|
source "$_bash_it_main_file_lib"
|
||||||
|
BASH_IT_LOG_PREFIX="core: main: "
|
||||||
done
|
done
|
||||||
unset _bash_it_vendor_init
|
|
||||||
|
|
||||||
BASH_IT_LOG_PREFIX="core: main: "
|
# Load the global "enabled" directory, then enabled aliases, completion, plugins
|
||||||
# Load the global "enabled" directory
|
# "_bash_it_main_file_type" param is empty so that files get sourced in glob order
|
||||||
# "family" param is empty so that files get sources in glob order
|
for _bash_it_main_file_type in "" "aliases" "plugins" "completion"; do
|
||||||
# shellcheck source=./scripts/reloader.bash
|
BASH_IT_LOG_PREFIX="core: reloader: "
|
||||||
source "${BASH_IT}/scripts/reloader.bash"
|
# shellcheck disable=SC2140
|
||||||
|
source "${BASH_IT}/scripts/reloader.bash" ${_bash_it_main_file_type:+"skip" "$_bash_it_main_file_type"}
|
||||||
# Load enabled aliases, completion, plugins
|
BASH_IT_LOG_PREFIX="core: main: "
|
||||||
for file_type in "aliases" "plugins" "completion"; do
|
|
||||||
# shellcheck source=./scripts/reloader.bash
|
|
||||||
source "${BASH_IT}/scripts/reloader.bash" "skip" "$file_type"
|
|
||||||
done
|
done
|
||||||
|
|
||||||
# Load theme, if a theme was set
|
# Load theme, if a theme was set
|
||||||
if [[ -n "${BASH_IT_THEME}" ]]; then
|
# shellcheck source-path=SCRIPTDIR/themes
|
||||||
_log_debug "Loading \"${BASH_IT_THEME}\" theme..."
|
if [[ -n "${BASH_IT_THEME:-}" ]]; then
|
||||||
# Load colors and helpers first so they can be used in base theme
|
_log_debug "Loading theme '${BASH_IT_THEME}'."
|
||||||
BASH_IT_LOG_PREFIX="themes: colors: "
|
|
||||||
# shellcheck source=./themes/colors.theme.bash
|
|
||||||
source "${BASH_IT}/themes/colors.theme.bash"
|
|
||||||
BASH_IT_LOG_PREFIX="themes: githelpers: "
|
BASH_IT_LOG_PREFIX="themes: githelpers: "
|
||||||
# shellcheck source=./themes/githelpers.theme.bash
|
|
||||||
source "${BASH_IT}/themes/githelpers.theme.bash"
|
source "${BASH_IT}/themes/githelpers.theme.bash"
|
||||||
BASH_IT_LOG_PREFIX="themes: p4helpers: "
|
BASH_IT_LOG_PREFIX="themes: p4helpers: "
|
||||||
# shellcheck source=./themes/p4helpers.theme.bash
|
|
||||||
source "${BASH_IT}/themes/p4helpers.theme.bash"
|
source "${BASH_IT}/themes/p4helpers.theme.bash"
|
||||||
BASH_IT_LOG_PREFIX="themes: command_duration: "
|
|
||||||
# shellcheck source=./themes/command_duration.theme.bash
|
|
||||||
source "${BASH_IT}/themes/command_duration.theme.bash"
|
|
||||||
BASH_IT_LOG_PREFIX="themes: base: "
|
BASH_IT_LOG_PREFIX="themes: base: "
|
||||||
# shellcheck source=./themes/base.theme.bash
|
|
||||||
source "${BASH_IT}/themes/base.theme.bash"
|
source "${BASH_IT}/themes/base.theme.bash"
|
||||||
|
|
||||||
BASH_IT_LOG_PREFIX="lib: appearance: "
|
BASH_IT_LOG_PREFIX="lib: appearance: "
|
||||||
# appearance (themes) now, after all dependencies
|
# appearance (themes) now, after all dependencies
|
||||||
# shellcheck source=./lib/appearance.bash
|
# shellcheck source=SCRIPTDIR/lib/appearance.bash
|
||||||
source "$APPEARANCE_LIB"
|
source "$APPEARANCE_LIB"
|
||||||
|
BASH_IT_LOG_PREFIX="core: main: "
|
||||||
fi
|
fi
|
||||||
|
|
||||||
BASH_IT_LOG_PREFIX="core: main: "
|
|
||||||
_log_debug "Loading custom aliases, completion, plugins..."
|
_log_debug "Loading custom aliases, completion, plugins..."
|
||||||
for file_type in "aliases" "completion" "plugins"; do
|
for _bash_it_main_file_type in "aliases" "completion" "plugins"; do
|
||||||
if [ -e "${BASH_IT}/${file_type}/custom.${file_type}.bash" ]; then
|
_bash_it_main_file_custom="${BASH_IT}/${_bash_it_main_file_type}/custom.${_bash_it_main_file_type}.bash"
|
||||||
BASH_IT_LOG_PREFIX="${file_type}: custom: "
|
if [[ -s "${_bash_it_main_file_custom}" ]]; then
|
||||||
|
_bash-it-log-prefix-by-path "${_bash_it_main_file_custom}"
|
||||||
_log_debug "Loading component..."
|
_log_debug "Loading component..."
|
||||||
# shellcheck disable=SC1090
|
# shellcheck disable=SC1090
|
||||||
source "${BASH_IT}/${file_type}/custom.${file_type}.bash"
|
source "${_bash_it_main_file_custom}"
|
||||||
fi
|
fi
|
||||||
|
BASH_IT_LOG_PREFIX="core: main: "
|
||||||
done
|
done
|
||||||
|
|
||||||
# Custom
|
# Custom
|
||||||
BASH_IT_LOG_PREFIX="core: main: "
|
|
||||||
_log_debug "Loading general custom files..."
|
_log_debug "Loading general custom files..."
|
||||||
CUSTOM="${BASH_IT_CUSTOM:=${BASH_IT}/custom}/*.bash ${BASH_IT_CUSTOM:=${BASH_IT}/custom}/**/*.bash"
|
for _bash_it_main_file_custom in "${BASH_IT_CUSTOM}"/*.bash "${BASH_IT_CUSTOM}"/*/*.bash; do
|
||||||
for _bash_it_config_file in $CUSTOM; do
|
if [[ -s "${_bash_it_main_file_custom}" ]]; then
|
||||||
if [ -e "${_bash_it_config_file}" ]; then
|
_bash-it-log-prefix-by-path "${_bash_it_main_file_custom}"
|
||||||
filename=$(basename "${_bash_it_config_file}")
|
|
||||||
filename=${filename%*.bash}
|
|
||||||
BASH_IT_LOG_PREFIX="custom: $filename: "
|
|
||||||
_log_debug "Loading custom file..."
|
_log_debug "Loading custom file..."
|
||||||
# shellcheck disable=SC1090
|
# shellcheck disable=SC1090
|
||||||
source "$_bash_it_config_file"
|
source "$_bash_it_main_file_custom"
|
||||||
fi
|
fi
|
||||||
|
BASH_IT_LOG_PREFIX="core: main: "
|
||||||
done
|
done
|
||||||
|
|
||||||
unset _bash_it_config_file
|
if [[ -n "${PROMPT:-}" ]]; then
|
||||||
if [[ $PROMPT ]]; then
|
PS1="${PROMPT}"
|
||||||
export PS1="\[""$PROMPT""\]"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Adding Support for other OSes
|
# Adding Support for other OSes
|
||||||
PREVIEW="less"
|
if _command_exists gloobus-preview; then
|
||||||
|
|
||||||
if [ -s /usr/bin/gloobus-preview ]; then
|
|
||||||
PREVIEW="gloobus-preview"
|
PREVIEW="gloobus-preview"
|
||||||
elif [ -s /Applications/Preview.app ]; then
|
elif [[ -d /Applications/Preview.app ]]; then
|
||||||
# shellcheck disable=SC2034
|
|
||||||
PREVIEW="/Applications/Preview.app"
|
PREVIEW="/Applications/Preview.app"
|
||||||
fi
|
else
|
||||||
|
PREVIEW="less"
|
||||||
# Load all the Jekyll stuff
|
|
||||||
|
|
||||||
if [ -e "$HOME/.jekyllconfig" ]; then
|
|
||||||
# shellcheck disable=SC1090
|
|
||||||
. "$HOME/.jekyllconfig"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# BASH_IT_RELOAD_LEGACY is set.
|
# BASH_IT_RELOAD_LEGACY is set.
|
||||||
if ! command -v reload &> /dev/null && [ -n "$BASH_IT_RELOAD_LEGACY" ]; then
|
if [[ -n "${BASH_IT_RELOAD_LEGACY:-}" ]] && ! _command_exists reload; then
|
||||||
case $OSTYPE in
|
# shellcheck disable=SC2139
|
||||||
darwin*)
|
alias reload="builtin source '${BASH_IT_BASHRC?}'"
|
||||||
alias reload='source ~/.bash_profile'
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
alias reload='source ~/.bashrc'
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Disable trap DEBUG on subshells - https://github.com/Bash-it/bash-it/pull/1040
|
for _bash_it_library_finalize_f in "${_bash_it_library_finalize_hook[@]:-}"; do
|
||||||
set +T
|
eval "${_bash_it_library_finalize_f?}" # Use `eval` to achieve the same behavior as `$PROMPT_COMMAND`.
|
||||||
|
done
|
||||||
|
unset "${!_bash_it_library_finalize_@}" "${!_bash_it_main_file_@}"
|
||||||
|
|
|
||||||
159
clean_files.txt
159
clean_files.txt
|
|
@ -1,7 +1,7 @@
|
||||||
#######################################################################
|
#######################################################################
|
||||||
# Allow-list of files to be lint-checked by CI
|
# Allow-list of files to be lint-checked by CI
|
||||||
#
|
#
|
||||||
# Directory Suport
|
# Directory Support
|
||||||
# Directory references are allowed within the file, ie:
|
# Directory references are allowed within the file, ie:
|
||||||
#
|
#
|
||||||
# themes/powerline
|
# themes/powerline
|
||||||
|
|
@ -16,71 +16,53 @@
|
||||||
|
|
||||||
# root directories
|
# root directories
|
||||||
#
|
#
|
||||||
docs
|
aliases/
|
||||||
hooks
|
docs/
|
||||||
|
hooks/
|
||||||
|
scripts/
|
||||||
|
|
||||||
# root files
|
# root files
|
||||||
#
|
#
|
||||||
.gitattributes
|
.gitattributes
|
||||||
lint_clean_files.sh
|
|
||||||
install.sh
|
|
||||||
bash_it.sh
|
bash_it.sh
|
||||||
|
clean_files.txt
|
||||||
# themes
|
install.sh
|
||||||
#
|
lint_clean_files.sh
|
||||||
themes/agnoster
|
|
||||||
themes/90210
|
|
||||||
themes/powerline
|
|
||||||
themes/barbuk
|
|
||||||
themes/atomic
|
|
||||||
themes/axin
|
|
||||||
themes/base.theme.bash
|
|
||||||
themes/bakke
|
|
||||||
themes/binaryanomaly
|
|
||||||
themes/bira
|
|
||||||
themes/bobby
|
|
||||||
themes/bobby-python
|
|
||||||
themes/brainy
|
|
||||||
themes/brunton
|
|
||||||
themes/command_duration.theme.bash
|
|
||||||
themes/modern
|
|
||||||
|
|
||||||
# plugins
|
|
||||||
#
|
|
||||||
plugins/available/basher.plugin.bash
|
|
||||||
plugins/available/cmd-returned-notify.plugin.bash
|
|
||||||
plugins/available/docker-machine.plugin.bash
|
|
||||||
plugins/available/git.plugin.bash
|
|
||||||
plugins/available/go.plugin.bash
|
|
||||||
plugins/available/goenv.plugin.bash
|
|
||||||
plugins/available/history.plugin.bash
|
|
||||||
plugins/available/history-search.plugin.bash
|
|
||||||
plugins/available/history-substring-search.plugin.bash
|
|
||||||
plugins/available/xterm.plugin.bash
|
|
||||||
|
|
||||||
# completions
|
# completions
|
||||||
#
|
#
|
||||||
completion/available/apm.completion.bash
|
completion/available/apm.completion.bash
|
||||||
completion/available/awless.completion.bash
|
completion/available/awless.completion.bash
|
||||||
|
completion/available/awscli.completion.bash
|
||||||
|
completion/available/bash-it.completion.bash
|
||||||
completion/available/brew.completion.bash
|
completion/available/brew.completion.bash
|
||||||
completion/available/cargo.completion.bash
|
completion/available/cargo.completion.bash
|
||||||
completion/available/composer.completion.bash
|
completion/available/composer.completion.bash
|
||||||
completion/available/conda.completion.bash
|
completion/available/conda.completion.bash
|
||||||
completion/available/consul.completion.bash
|
completion/available/consul.completion.bash
|
||||||
|
completion/available/dart.completion.bash
|
||||||
completion/available/django.completion.bash
|
completion/available/django.completion.bash
|
||||||
completion/available/docker.completion.bash
|
completion/available/dmidecode.completion.bash
|
||||||
completion/available/docker-machine.completion.bash
|
completion/available/docker-machine.completion.bash
|
||||||
|
completion/available/docker.completion.bash
|
||||||
|
completion/available/dotnet.completion.bash
|
||||||
|
completion/available/flutter.completion.bash
|
||||||
completion/available/gcloud.completion.bash
|
completion/available/gcloud.completion.bash
|
||||||
completion/available/gem.completion.bash
|
completion/available/gem.completion.bash
|
||||||
completion/available/go.completion.bash
|
completion/available/git.completion.bash
|
||||||
completion/available/github-cli.completion.bash
|
completion/available/github-cli.completion.bash
|
||||||
|
completion/available/go.completion.bash
|
||||||
completion/available/helm.completion.bash
|
completion/available/helm.completion.bash
|
||||||
|
completion/available/jboss5.completion.bash
|
||||||
|
completion/available/jboss7.completion.bash
|
||||||
completion/available/jungle.completion.bash
|
completion/available/jungle.completion.bash
|
||||||
completion/available/knife.completion.bash
|
completion/available/knife.completion.bash
|
||||||
completion/available/kontena.completion.bash
|
completion/available/kontena.completion.bash
|
||||||
completion/available/kubectl.completion.bash
|
completion/available/kubectl.completion.bash
|
||||||
|
completion/available/laravel.completion.bash
|
||||||
completion/available/lerna.completion.bash
|
completion/available/lerna.completion.bash
|
||||||
completion/available/minikube.completion.bash
|
completion/available/minikube.completion.bash
|
||||||
|
completion/available/ngrok.completion.bash
|
||||||
completion/available/notify-send.completion.bash
|
completion/available/notify-send.completion.bash
|
||||||
completion/available/npm.completion.bash
|
completion/available/npm.completion.bash
|
||||||
completion/available/packer.completion.bash
|
completion/available/packer.completion.bash
|
||||||
|
|
@ -89,19 +71,106 @@ completion/available/pip3.completion.bash
|
||||||
completion/available/pipenv.completion.bash
|
completion/available/pipenv.completion.bash
|
||||||
completion/available/pipx.completion.bash
|
completion/available/pipx.completion.bash
|
||||||
completion/available/rustup.completion.bash
|
completion/available/rustup.completion.bash
|
||||||
completion/available/vault.completion.bash
|
|
||||||
completion/available/sdkman.completion.bash
|
completion/available/sdkman.completion.bash
|
||||||
|
completion/available/system.completion.bash
|
||||||
|
completion/available/vault.completion.bash
|
||||||
completion/available/vuejs.completion.bash
|
completion/available/vuejs.completion.bash
|
||||||
|
completion/available/wpscan.completion.bash
|
||||||
|
completion/available/yarn.completion.bash
|
||||||
|
|
||||||
# aliases
|
# libraries
|
||||||
|
lib/appearance.bash
|
||||||
|
lib/colors.bash
|
||||||
|
lib/command_duration.bash
|
||||||
|
lib/helpers.bash
|
||||||
|
lib/history.bash
|
||||||
|
lib/log.bash
|
||||||
|
lib/preexec.bash
|
||||||
|
lib/preview.bash
|
||||||
|
lib/search.bash
|
||||||
|
lib/utilities.bash
|
||||||
|
|
||||||
|
# plugins
|
||||||
#
|
#
|
||||||
aliases/available/dnf.aliases.bash
|
plugins/available/alias-completion.plugin.bash
|
||||||
aliases/available/vim.aliases.bash
|
plugins/available/autojump.plugin.bash
|
||||||
aliases/available/git.aliases.bash
|
plugins/available/base.plugin.bash
|
||||||
|
plugins/available/basher.plugin.bash
|
||||||
|
plugins/available/battery.plugin.bash
|
||||||
|
plugins/available/blesh.plugin.bash
|
||||||
|
plugins/available/cmd-returned-notify.plugin.bash
|
||||||
|
plugins/available/colors.plugin.bash
|
||||||
|
plugins/available/direnv.plugin.bash
|
||||||
|
plugins/available/dirs.plugin.bash
|
||||||
|
plugins/available/docker-machine.plugin.bash
|
||||||
|
plugins/available/gif.plugin.bash
|
||||||
|
plugins/available/git-subrepo.plugin.bash
|
||||||
|
plugins/available/git.plugin.bash
|
||||||
|
plugins/available/go.plugin.bash
|
||||||
|
plugins/available/goenv.plugin.bash
|
||||||
|
plugins/available/history-eternal.plugin.bash
|
||||||
|
plugins/available/history-search.plugin.bash
|
||||||
|
plugins/available/history-substring-search.plugin.bash
|
||||||
|
plugins/available/history.plugin.bash
|
||||||
|
plugins/available/hub.plugin.bash
|
||||||
|
plugins/available/java.plugin.bash
|
||||||
|
plugins/available/jekyll.plugin.bash
|
||||||
|
plugins/available/jump.plugin.bash
|
||||||
|
plugins/available/latex.plugin.bash
|
||||||
|
plugins/available/less-pretty-cat.plugin.bash
|
||||||
|
plugins/available/man.plugin.bash
|
||||||
|
plugins/available/nginx.plugin.bash
|
||||||
|
plugins/available/node.plugin.bash
|
||||||
|
plugins/available/nodenv.plugin.bash
|
||||||
|
plugins/available/osx-timemachine.plugin.bash
|
||||||
|
plugins/available/osx.plugin.bash
|
||||||
|
plugins/available/percol.plugin.bash
|
||||||
|
plugins/available/plenv.plugin.bash
|
||||||
|
plugins/available/projects.plugin.bash
|
||||||
|
plugins/available/proxy.plugin.bash
|
||||||
|
plugins/available/pyenv.plugin.bash
|
||||||
|
plugins/available/python.plugin.bash
|
||||||
|
plugins/available/rbenv.plugin.bash
|
||||||
|
plugins/available/ruby.plugin.bash
|
||||||
|
plugins/available/textmate.plugin.bash
|
||||||
|
plugins/available/todo.plugin.bash
|
||||||
|
plugins/available/xterm.plugin.bash
|
||||||
|
plugins/available/zoxide.plugin.bash
|
||||||
|
|
||||||
# tests
|
# tests
|
||||||
|
#
|
||||||
|
test/completion/aliases.completion.bats
|
||||||
|
test/run
|
||||||
test/test_helper.bash
|
test/test_helper.bash
|
||||||
|
|
||||||
|
# themes
|
||||||
|
#
|
||||||
|
themes/90210
|
||||||
|
themes/agnoster
|
||||||
|
themes/atomic
|
||||||
|
themes/axin
|
||||||
|
themes/bakke
|
||||||
|
themes/barbuk
|
||||||
|
themes/base.theme.bash
|
||||||
|
themes/binaryanomaly
|
||||||
|
themes/bira
|
||||||
|
themes/bobby
|
||||||
|
themes/bobby-python
|
||||||
|
themes/brainy
|
||||||
|
themes/brunton
|
||||||
|
themes/candy
|
||||||
|
themes/easy
|
||||||
|
themes/essential
|
||||||
|
themes/githelpers.theme.bash
|
||||||
|
themes/modern
|
||||||
|
themes/norbu
|
||||||
|
themes/oh-my-posh
|
||||||
|
themes/p4helpers.theme.bash
|
||||||
|
themes/pete
|
||||||
|
themes/powerline
|
||||||
|
themes/pure
|
||||||
|
themes/purity
|
||||||
|
|
||||||
# vendor init files
|
# vendor init files
|
||||||
|
#
|
||||||
vendor/.gitattributes
|
vendor/.gitattributes
|
||||||
vendor/init.d
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,112 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
about-plugin 'Automatic completion of aliases'
|
||||||
|
# Load after all aliases and completions to understand what needs to be completed
|
||||||
|
# BASH_IT_LOAD_PRIORITY: 800
|
||||||
|
|
||||||
|
# References:
|
||||||
|
# http://superuser.com/a/437508/119764
|
||||||
|
# http://stackoverflow.com/a/1793178/1228454
|
||||||
|
|
||||||
|
# Automatically add completion for all aliases to commands having completion functions
|
||||||
|
function _bash-it-component-completion-callback-on-init-aliases() {
|
||||||
|
local namespace="alias_completion"
|
||||||
|
local tmp_file completion_loader alias_name line completions chars
|
||||||
|
local alias_arg_words new_completion compl_func compl_wrapper alias_defn
|
||||||
|
|
||||||
|
# create array of function completion triggers, keeping multi-word triggers together
|
||||||
|
IFS=$'\n' read -d '' -ra completions < <(complete -p)
|
||||||
|
((${#completions[@]} == 0)) && return 0
|
||||||
|
|
||||||
|
completions=("${completions[@]##complete -* * -}") # strip all but last option plus trigger(s)
|
||||||
|
completions=("${completions[@]#complete -}") # strip anything missed
|
||||||
|
completions=("${completions[@]#? * }") # strip last option and arg, leaving only trigger(s)
|
||||||
|
completions=("${completions[@]#? }") # strip anything missed
|
||||||
|
#TODO: this will fail on some completions...
|
||||||
|
|
||||||
|
# create temporary file for wrapper functions and completions
|
||||||
|
tmp_file="$(mktemp -t "${namespace}-${RANDOM}XXXXXX")" || return 1
|
||||||
|
|
||||||
|
IFS=$'\n' read -r completion_loader < <(complete -p -D 2> /dev/null)
|
||||||
|
if [[ "${completion_loader#complete }" =~ '-F'[[:space:]]([[:alnum:]_]+)[[:space:]] ]]; then
|
||||||
|
completion_loader="${BASH_REMATCH[1]}"
|
||||||
|
else
|
||||||
|
completion_loader=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
# read in "<alias> '<aliased command>' '<command args>'" lines from defined aliases
|
||||||
|
# some aliases do have backslashes that needs to be interpreted
|
||||||
|
# shellcheck disable=SC2162
|
||||||
|
while read line; do
|
||||||
|
line="${line#alias -- }"
|
||||||
|
line="${line#alias }"
|
||||||
|
alias_name="${line%%=*}"
|
||||||
|
alias_defn="${line#*=\'}" # alias definition
|
||||||
|
alias_defn="${alias_defn%\'}"
|
||||||
|
alias_cmd="${alias_defn%%[[:space:]]*}" # first word of alias
|
||||||
|
if [[ ${alias_defn} == ${alias_cmd} ]]; then
|
||||||
|
alias_args=''
|
||||||
|
else
|
||||||
|
alias_args="${alias_defn#*[[:space:]]}" # everything after first word
|
||||||
|
fi
|
||||||
|
|
||||||
|
# skip aliases to pipes, boolean control structures and other command lists
|
||||||
|
chars=$'|&;()<>\n'
|
||||||
|
if [[ "${alias_defn}" =~ [$chars] ]]; then
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
# avoid expanding wildcards
|
||||||
|
read -ra alias_arg_words <<< "$alias_args"
|
||||||
|
|
||||||
|
# skip alias if there is no completion function triggered by the aliased command
|
||||||
|
if ! _bash-it-array-contains-element "$alias_cmd" "${completions[@]}"; then
|
||||||
|
if [[ -n "$completion_loader" ]]; then
|
||||||
|
# force loading of completions for the aliased command
|
||||||
|
"${completion_loader:?}" "${alias_cmd}"
|
||||||
|
# 124 means completion loader was successful
|
||||||
|
[[ $? -eq 124 ]] || continue
|
||||||
|
completions+=("$alias_cmd")
|
||||||
|
else
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
new_completion="$(complete -p "$alias_cmd" 2> /dev/null)"
|
||||||
|
|
||||||
|
# create a wrapper inserting the alias arguments if any
|
||||||
|
if [[ -n $alias_args ]]; then
|
||||||
|
compl_func="${new_completion/#* -F /}"
|
||||||
|
compl_func="${compl_func%% *}"
|
||||||
|
# avoid recursive call loops by ignoring our own functions
|
||||||
|
if [[ "${compl_func#_"$namespace"::}" == "$compl_func" ]]; then
|
||||||
|
compl_wrapper="_${namespace}::${alias_name}"
|
||||||
|
echo "function $compl_wrapper {
|
||||||
|
local compl_word=\${2?}
|
||||||
|
local prec_word=\${3?}
|
||||||
|
# check if prec_word is the alias itself. if so, replace it
|
||||||
|
# with the last word in the unaliased form, i.e.,
|
||||||
|
# alias_cmd + ' ' + alias_args.
|
||||||
|
if [[ \$COMP_LINE == \"\$prec_word \$compl_word\" ]]; then
|
||||||
|
prec_word='$alias_cmd $alias_args'
|
||||||
|
prec_word=\${prec_word#* }
|
||||||
|
fi
|
||||||
|
(( COMP_CWORD += ${#alias_arg_words[@]} ))
|
||||||
|
COMP_WORDS=(\"$alias_cmd\" \"${alias_arg_words[@]}\" \"\${COMP_WORDS[@]:1}\")
|
||||||
|
(( COMP_POINT -= \${#COMP_LINE} ))
|
||||||
|
COMP_LINE=\${COMP_LINE/$alias_name/$alias_cmd $alias_args}
|
||||||
|
(( COMP_POINT += \${#COMP_LINE} ))
|
||||||
|
\"$compl_func\" \"$alias_cmd\" \"\$compl_word\" \"\$prec_word\"
|
||||||
|
}" >> "$tmp_file"
|
||||||
|
new_completion="${new_completion/ -F $compl_func / -F $compl_wrapper }"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
# replace completion trigger by alias
|
||||||
|
if [[ -n $new_completion ]]; then
|
||||||
|
new_completion="${new_completion% *} $alias_name"
|
||||||
|
echo "$new_completion" >> "$tmp_file"
|
||||||
|
fi
|
||||||
|
done < <(alias -p)
|
||||||
|
# shellcheck source=/dev/null
|
||||||
|
source "$tmp_file" && command rm -f "$tmp_file"
|
||||||
|
}
|
||||||
|
|
||||||
|
_bash-it-component-completion-callback-on-init-aliases
|
||||||
|
|
@ -1 +1,5 @@
|
||||||
[[ -x "$(which aws_completer)" ]] && complete -C "$(which aws_completer)" aws
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
if _command_exists aws_completer; then
|
||||||
|
complete -C "$(command -v aws_completer)" aws
|
||||||
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,140 +1,95 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
_bash-it-comp-enable-disable()
|
function _compreply_candidates() {
|
||||||
{
|
local IFS=$'\n'
|
||||||
local enable_disable_args="alias completion plugin"
|
|
||||||
COMPREPLY=( $(compgen -W "${enable_disable_args}" -- ${cur}) )
|
read -d '' -ra COMPREPLY < <(compgen -W "${candidates[*]}" -- "${cur}")
|
||||||
}
|
}
|
||||||
|
|
||||||
_bash-it-comp-list-available-not-enabled()
|
function _bash-it() {
|
||||||
{
|
local cur prev verb file_type candidates suffix
|
||||||
subdirectory="$1"
|
COMPREPLY=()
|
||||||
|
cur="${COMP_WORDS[COMP_CWORD]}"
|
||||||
|
prev="${COMP_WORDS[COMP_CWORD - 1]}"
|
||||||
|
verb="${COMP_WORDS[1]}"
|
||||||
|
file_type="${COMP_WORDS[2]:-}"
|
||||||
|
candidates=('disable' 'enable' 'help' 'migrate' 'reload' 'restart' 'preview' 'profile' 'doctor' 'search' 'show' 'update' 'version')
|
||||||
|
case "${verb}" in
|
||||||
|
show)
|
||||||
|
candidates=('aliases' 'completions' 'plugins')
|
||||||
|
_compreply_candidates
|
||||||
|
;;
|
||||||
|
help)
|
||||||
|
if [[ "${prev}" == "aliases" ]]; then
|
||||||
|
candidates=('all' "$(_bash-it-component-list "${file_type}")")
|
||||||
|
_compreply_candidates
|
||||||
|
else
|
||||||
|
candidates=('aliases' 'completions' 'migrate' 'plugins' 'update')
|
||||||
|
_compreply_candidates
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
profile)
|
||||||
|
case "${file_type}" in
|
||||||
|
load | rm)
|
||||||
|
if [[ "${file_type}" == "$prev" ]]; then
|
||||||
|
candidates=("${BASH_IT}/profiles"/*.bash_it)
|
||||||
|
candidates=("${candidates[@]##*/}")
|
||||||
|
candidates=("${candidates[@]%%.bash_it}")
|
||||||
|
|
||||||
local available_things
|
_compreply_candidates
|
||||||
|
fi
|
||||||
available_things=$(for f in `compgen -G "${BASH_IT}/$subdirectory/available/*.bash" | sort -d`;
|
;;
|
||||||
do
|
save | list) ;;
|
||||||
file_entity=$(basename $f)
|
*)
|
||||||
|
candidates=('load' 'save' 'list' 'rm')
|
||||||
typeset enabled_component=$(command ls "${BASH_IT}/$subdirectory/enabled/"{[0-9]*$BASH_IT_LOAD_PRIORITY_SEPARATOR$file_entity,$file_entity} 2>/dev/null | head -1)
|
_compreply_candidates
|
||||||
typeset enabled_component_global=$(command ls "${BASH_IT}/enabled/"[0-9]*$BASH_IT_LOAD_PRIORITY_SEPARATOR$file_entity 2>/dev/null | head -1)
|
;;
|
||||||
|
esac
|
||||||
if [ -z "$enabled_component" ] && [ -z "$enabled_component_global" ]
|
;;
|
||||||
then
|
doctor)
|
||||||
basename $f | sed -e 's/\(.*\)\..*\.bash/\1/g'
|
candidates=('errors' 'warnings' 'all')
|
||||||
fi
|
_compreply_candidates
|
||||||
done)
|
;;
|
||||||
|
update)
|
||||||
COMPREPLY=( $(compgen -W "all ${available_things}" -- ${cur}) )
|
if [[ "${cur}" == -* ]]; then
|
||||||
}
|
candidates=('-s' '--silent')
|
||||||
|
else
|
||||||
_bash-it-comp-list-enabled()
|
candidates=('stable' 'dev')
|
||||||
{
|
fi
|
||||||
local subdirectory="$1"
|
_compreply_candidates
|
||||||
local suffix enabled_things
|
;;
|
||||||
|
migrate | reload | restart | search | version) ;;
|
||||||
suffix=$(echo "$subdirectory" | sed -e 's/plugins/plugin/g')
|
preview)
|
||||||
|
_bash-it-preview # completes itself
|
||||||
enabled_things=$(for f in `sort -d <(compgen -G "${BASH_IT}/$subdirectory/enabled/*.${suffix}.bash") <(compgen -G "${BASH_IT}/enabled/*.${suffix}.bash")`;
|
return 0
|
||||||
do
|
;;
|
||||||
basename $f | sed -e 's/\(.*\)\..*\.bash/\1/g' | sed -e "s/^[0-9]*---//g"
|
enable | disable)
|
||||||
done)
|
if [[ "${verb}" == "enable" ]]; then
|
||||||
|
suffix="disabled"
|
||||||
COMPREPLY=( $(compgen -W "all ${enabled_things}" -- ${cur}) )
|
else
|
||||||
}
|
suffix="enabled"
|
||||||
|
fi
|
||||||
_bash-it-comp-list-available()
|
case "${file_type}" in
|
||||||
{
|
alias | completion | plugin)
|
||||||
subdirectory="$1"
|
candidates=('all' "$("_bash-it-component-list-${suffix}" "${file_type}")")
|
||||||
|
_compreply_candidates
|
||||||
local enabled_things
|
;;
|
||||||
|
*)
|
||||||
enabled_things=$(for f in `compgen -G "${BASH_IT}/$subdirectory/available/*.bash" | sort -d`;
|
candidates=('alias' 'completion' 'plugin')
|
||||||
do
|
_compreply_candidates
|
||||||
basename $f | sed -e 's/\(.*\)\..*\.bash/\1/g'
|
;;
|
||||||
done)
|
esac
|
||||||
|
;;
|
||||||
COMPREPLY=( $(compgen -W "${enabled_things}" -- ${cur}) )
|
*)
|
||||||
}
|
_compreply_candidates
|
||||||
|
;;
|
||||||
_bash-it-comp()
|
esac
|
||||||
{
|
|
||||||
local cur prev opts
|
|
||||||
COMPREPLY=()
|
|
||||||
cur="${COMP_WORDS[COMP_CWORD]}"
|
|
||||||
prev="${COMP_WORDS[COMP_CWORD-1]}"
|
|
||||||
chose_opt="${COMP_WORDS[1]}"
|
|
||||||
file_type="${COMP_WORDS[2]}"
|
|
||||||
opts="disable enable help migrate reload restart doctor search show update version"
|
|
||||||
case "${chose_opt}" in
|
|
||||||
show)
|
|
||||||
local show_args="aliases completions plugins"
|
|
||||||
COMPREPLY=( $(compgen -W "${show_args}" -- ${cur}) )
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
help)
|
|
||||||
if [ x"${prev}" == x"aliases" ]; then
|
|
||||||
_bash-it-comp-list-available aliases
|
|
||||||
return 0
|
|
||||||
else
|
|
||||||
local help_args="aliases completions migrate plugins update"
|
|
||||||
COMPREPLY=( $(compgen -W "${help_args}" -- ${cur}) )
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
doctor)
|
|
||||||
local doctor_args="errors warnings all"
|
|
||||||
COMPREPLY=( $(compgen -W "${doctor_args}" -- ${cur}) )
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
update)
|
|
||||||
if [[ ${cur} == -* ]];then
|
|
||||||
local update_args="-s --silent"
|
|
||||||
else
|
|
||||||
local update_args="stable dev"
|
|
||||||
fi
|
|
||||||
COMPREPLY=( $(compgen -W "${update_args}" -- ${cur}) )
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
migrate | reload | search | version)
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
enable | disable)
|
|
||||||
if [ x"${chose_opt}" == x"enable" ];then
|
|
||||||
suffix="available-not-enabled"
|
|
||||||
else
|
|
||||||
suffix="enabled"
|
|
||||||
fi
|
|
||||||
case "${file_type}" in
|
|
||||||
alias)
|
|
||||||
_bash-it-comp-list-${suffix} aliases
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
plugin)
|
|
||||||
_bash-it-comp-list-${suffix} plugins
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
completion)
|
|
||||||
_bash-it-comp-list-${suffix} completion
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
_bash-it-comp-enable-disable
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# Activate completion for bash-it and its common misspellings
|
# Activate completion for bash-it and its common misspellings
|
||||||
complete -F _bash-it-comp bash-it
|
complete -F _bash-it bash-it
|
||||||
complete -F _bash-it-comp bash-ti
|
complete -F _bash-it bash-ti
|
||||||
complete -F _bash-it-comp shit
|
complete -F _bash-it shit
|
||||||
complete -F _bash-it-comp bashit
|
complete -F _bash-it bashit
|
||||||
complete -F _bash-it-comp batshit
|
complete -F _bash-it batshit
|
||||||
complete -F _bash-it-comp bash_it
|
complete -F _bash-it bash_it
|
||||||
|
|
|
||||||
|
|
@ -5,28 +5,26 @@ about-completion "brew completion"
|
||||||
# Load late to make sure `system` completion loads first
|
# Load late to make sure `system` completion loads first
|
||||||
# BASH_IT_LOAD_PRIORITY: 375
|
# BASH_IT_LOAD_PRIORITY: 375
|
||||||
|
|
||||||
if [[ "$(uname -s)" != 'Darwin' ]]; then
|
if [[ "$OSTYPE" != 'darwin'* ]]; then
|
||||||
_log_warning "unsupported operating system - only 'Darwin' is supported"
|
_log_warning "unsupported operating system - only 'Darwin' is supported"
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Make sure brew is installed
|
# Make sure brew is installed
|
||||||
_command_exists brew || return 0
|
_bash_it_homebrew_check || return 0
|
||||||
|
|
||||||
BREW_PREFIX=${BREW_PREFIX:-$(brew --prefix)}
|
if [[ -r "$BASH_IT_HOMEBREW_PREFIX/etc/bash_completion.d/brew" ]]; then
|
||||||
|
# shellcheck disable=1090,1091
|
||||||
|
source "$BASH_IT_HOMEBREW_PREFIX/etc/bash_completion.d/brew"
|
||||||
|
|
||||||
if [[ -r "$BREW_PREFIX"/etc/bash_completion.d/brew ]]; then
|
elif [[ -r "$BASH_IT_HOMEBREW_PREFIX/Library/Contributions/brew_bash_completion.sh" ]]; then
|
||||||
# shellcheck disable=1090
|
# shellcheck disable=1090,1091
|
||||||
source "$BREW_PREFIX"/etc/bash_completion.d/brew
|
source "$BASH_IT_HOMEBREW_PREFIX/Library/Contributions/brew_bash_completion.sh"
|
||||||
|
|
||||||
elif [[ -r "$BREW_PREFIX"/Library/Contributions/brew_bash_completion.sh ]]; then
|
elif [[ -f "$BASH_IT_HOMEBREW_PREFIX/completions/bash/brew" ]]; then
|
||||||
# shellcheck disable=1090
|
|
||||||
source "$BREW_PREFIX"/Library/Contributions/brew_bash_completion.sh
|
|
||||||
|
|
||||||
elif [[ -f "$BREW_PREFIX"/completions/bash/brew ]]; then
|
|
||||||
# For the git-clone based installation, see here for more info:
|
# For the git-clone based installation, see here for more info:
|
||||||
# https://github.com/Bash-it/bash-it/issues/1458
|
# https://github.com/Bash-it/bash-it/issues/1458
|
||||||
# https://docs.brew.sh/Shell-Completion
|
# https://docs.brew.sh/Shell-Completion
|
||||||
# shellcheck disable=1090
|
# shellcheck disable=1090,1091
|
||||||
source "$BREW_PREFIX"/completions/bash/brew
|
source "$BASH_IT_HOMEBREW_PREFIX/completions/bash/brew"
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -3,14 +3,14 @@ cite "about-completion"
|
||||||
about-completion "composer completion"
|
about-completion "composer completion"
|
||||||
|
|
||||||
function __composer_completion() {
|
function __composer_completion() {
|
||||||
local cur coms opts com
|
local cur coms opts com words
|
||||||
COMPREPLY=()
|
COMPREPLY=()
|
||||||
_get_comp_words_by_ref -n : cur words
|
_get_comp_words_by_ref -n : cur words
|
||||||
|
|
||||||
# lookup for command
|
# lookup for command
|
||||||
for word in "${words[@]:1}"; do
|
for word in "${words[@]:1}"; do
|
||||||
if [[ $word != -* ]]; then
|
if [[ "${word}" != -* ]]; then
|
||||||
com=$word
|
com="${word}"
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
@ -19,7 +19,7 @@ function __composer_completion() {
|
||||||
if [[ ${cur} == --* ]]; then
|
if [[ ${cur} == --* ]]; then
|
||||||
opts="--help --quiet --verbose --version --ansi --no-ansi --no-interaction --profile --no-plugins --working-dir"
|
opts="--help --quiet --verbose --version --ansi --no-ansi --no-interaction --profile --no-plugins --working-dir"
|
||||||
|
|
||||||
case "$com" in
|
case "${com}" in
|
||||||
about)
|
about)
|
||||||
opts="${opts} "
|
opts="${opts} "
|
||||||
;;
|
;;
|
||||||
|
|
@ -109,18 +109,18 @@ function __composer_completion() {
|
||||||
|
|
||||||
# shellcheck disable=SC2207
|
# shellcheck disable=SC2207
|
||||||
COMPREPLY=($(compgen -W "${opts}" -- "${cur}"))
|
COMPREPLY=($(compgen -W "${opts}" -- "${cur}"))
|
||||||
__ltrim_colon_completions "$cur"
|
__ltrim_colon_completions "${cur}"
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# completing for a command
|
# completing for a command
|
||||||
if [[ "$cur" == "$com" ]]; then
|
if [[ "${cur}" == "${com}" ]]; then
|
||||||
coms="about archive browse clear-cache config create-project depends diagnose dump-autoload exec global help init install licenses list outdated prohibits remove require run-script search self-update show status suggests update validate"
|
coms="about archive browse clear-cache config create-project depends diagnose dump-autoload exec global help init install licenses list outdated prohibits remove require run-script search self-update show status suggests update validate"
|
||||||
|
|
||||||
# shellcheck disable=SC2207
|
# shellcheck disable=SC2207
|
||||||
COMPREPLY=($(compgen -W "${coms}" -- "${cur}"))
|
COMPREPLY=($(compgen -W "${coms}" -- "${cur}"))
|
||||||
__ltrim_colon_completions "$cur"
|
__ltrim_colon_completions "${cur}"
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -3,5 +3,5 @@ cite "about-completion"
|
||||||
about-completion "Hashicorp consul completion"
|
about-completion "Hashicorp consul completion"
|
||||||
|
|
||||||
if _command_exists consul; then
|
if _command_exists consul; then
|
||||||
complete -C "$(which consul)" consul
|
complete -C "$(command -v consul)" consul
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,48 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
__dart_completion() {
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
local prev=$(_get_pword)
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
local curr=$(_get_cword)
|
||||||
|
|
||||||
|
local HELP="--help -h"
|
||||||
|
local VERBOSE="-v --verbose"
|
||||||
|
|
||||||
|
case $prev in
|
||||||
|
analyze)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$HELP --fatal-infos --no-fatal-warnings --fatal-warnings" -- "$curr"))
|
||||||
|
;;
|
||||||
|
compile)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$HELP aot-snapshot exe js jit-snapshot kernel" -- "$curr"))
|
||||||
|
;;
|
||||||
|
create)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$HELP --template -t --no-pub --pub --force" -- "$curr"))
|
||||||
|
;;
|
||||||
|
-t | --template)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "console-simple console-full package-simple web-simple" -- "$curr"))
|
||||||
|
;;
|
||||||
|
format)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$HELP $VERBOSE -o --output --fix -l --line-length" -- "$curr"))
|
||||||
|
;;
|
||||||
|
pub)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$HELP $VERBOSE --version --no-trace --trace --verbosity cache deps downgrade get global logout outdated publish run upgrade uploader version" -- "$curr"))
|
||||||
|
;;
|
||||||
|
run)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$HELP --observe --enable-vm-service --no-pause-isolates-on-exit --no-pause-isolates-on-unhandled-exceptions --no-warn-on-pause-with-no-debugger --pause-isolates-on-exit --pause-isolates-on-unhandled-exceptions --warn-on-pause-with-no-debugger" -- "$curr"))
|
||||||
|
;;
|
||||||
|
dart)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$HELP $VERBOSE --version --enable-analytics --disable-analytics help analyze compile create format pub run test" -- "$curr"))
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
complete -F __dart_completion dart
|
||||||
|
|
@ -1,175 +1,5 @@
|
||||||
# defaults
|
# shellcheck shell=bash
|
||||||
# Bash command line completion for defaults
|
|
||||||
#
|
|
||||||
# Created by Jonathon Mah on 2006-11-08.
|
|
||||||
# Copyright 2006 Playhaus. All rights reserved.
|
|
||||||
#
|
|
||||||
# Version 1.0 (2006-11-08)
|
|
||||||
|
|
||||||
|
if test -s "${BASH_IT?}/vendor/github.com/gaelicWizard/bash-progcomp/defaults.completion.bash"; then
|
||||||
_defaults_domains()
|
source "$_"
|
||||||
{
|
fi
|
||||||
local cur
|
|
||||||
COMPREPLY=()
|
|
||||||
cur=${COMP_WORDS[COMP_CWORD]}
|
|
||||||
|
|
||||||
local domains=$( defaults domains | sed -e 's/, /:/g' | tr : '\n' | sed -e 's/ /\\ /g' | grep -i "^$cur" )
|
|
||||||
local IFS=$'\n'
|
|
||||||
COMPREPLY=( $domains )
|
|
||||||
if [[ $( echo '-app' | grep "^$cur" ) ]]; then
|
|
||||||
COMPREPLY[${#COMPREPLY[@]}]="-app"
|
|
||||||
fi
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
_defaults()
|
|
||||||
{
|
|
||||||
local cur prev host_opts cmds cmd domain keys key_index
|
|
||||||
cur=${COMP_WORDS[COMP_CWORD]}
|
|
||||||
prev=${COMP_WORDS[COMP_CWORD-1]}
|
|
||||||
|
|
||||||
host_opts='-currentHost -host'
|
|
||||||
cmds='read read-type write rename delete domains find help'
|
|
||||||
|
|
||||||
if [[ $COMP_CWORD -eq 1 ]]; then
|
|
||||||
COMPREPLY=( $( compgen -W "$host_opts $cmds" -- $cur ) )
|
|
||||||
return 0
|
|
||||||
elif [[ $COMP_CWORD -eq 2 ]]; then
|
|
||||||
if [[ "$prev" == "-currentHost" ]]; then
|
|
||||||
COMPREPLY=( $( compgen -W "$cmds" -- $cur ) )
|
|
||||||
return 0
|
|
||||||
elif [[ "$prev" == "-host" ]]; then
|
|
||||||
return 0
|
|
||||||
_known_hosts -a
|
|
||||||
else
|
|
||||||
_defaults_domains
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
elif [[ $COMP_CWORD -eq 3 ]]; then
|
|
||||||
if [[ ${COMP_WORDS[1]} == "-host" ]]; then
|
|
||||||
_defaults_domains
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Both a domain and command have been specified
|
|
||||||
|
|
||||||
if [[ ${COMP_WORDS[1]} == [${cmds// /|}] ]]; then
|
|
||||||
cmd=${COMP_WORDS[1]}
|
|
||||||
domain=${COMP_WORDS[2]}
|
|
||||||
key_index=3
|
|
||||||
if [[ "$domain" == "-app" ]]; then
|
|
||||||
if [[ $COMP_CWORD -eq 3 ]]; then
|
|
||||||
# Completing application name. Can't help here, sorry
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
domain="-app ${COMP_WORDS[3]}"
|
|
||||||
key_index=4
|
|
||||||
fi
|
|
||||||
elif [[ ${COMP_WORDS[2]} == "-currentHost" ]] && [[ ${COMP_WORDS[2]} == [${cmds// /|}] ]]; then
|
|
||||||
cmd=${COMP_WORDS[2]}
|
|
||||||
domain=${COMP_WORDS[3]}
|
|
||||||
key_index=4
|
|
||||||
if [[ "$domain" == "-app" ]]; then
|
|
||||||
if [[ $COMP_CWORD -eq 4 ]]; then
|
|
||||||
# Completing application name. Can't help here, sorry
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
domain="-app ${COMP_WORDS[4]}"
|
|
||||||
key_index=5
|
|
||||||
fi
|
|
||||||
elif [[ ${COMP_WORDS[3]} == "-host" ]] && [[ ${COMP_WORDS[3]} == [${cmds// /|}] ]]; then
|
|
||||||
cmd=${COMP_WORDS[3]}
|
|
||||||
domain=${COMP_WORDS[4]}
|
|
||||||
key_index=5
|
|
||||||
if [[ "$domain" == "-app" ]]; then
|
|
||||||
if [[ $COMP_CWORD -eq 5 ]]; then
|
|
||||||
# Completing application name. Can't help here, sorry
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
domain="-app ${COMP_WORDS[5]}"
|
|
||||||
key_index=6
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
keys=$( defaults read $domain 2>/dev/null | sed -n -e '/^ [^}) ]/p' | sed -e 's/^ \([^" ]\{1,\}\) = .*$/\1/g' -e 's/^ "\([^"]\{1,\}\)" = .*$/\1/g' | sed -e 's/ /\\ /g' )
|
|
||||||
|
|
||||||
case $cmd in
|
|
||||||
read|read-type)
|
|
||||||
# Complete key
|
|
||||||
local IFS=$'\n'
|
|
||||||
COMPREPLY=( $( echo "$keys" | grep -i "^${cur//\\/\\\\}" ) )
|
|
||||||
;;
|
|
||||||
write)
|
|
||||||
if [[ $key_index -eq $COMP_CWORD ]]; then
|
|
||||||
# Complete key
|
|
||||||
local IFS=$'\n'
|
|
||||||
COMPREPLY=( $( echo "$keys" | grep -i "^${cur//\\/\\\\}" ) )
|
|
||||||
elif [[ $((key_index+1)) -eq $COMP_CWORD ]]; then
|
|
||||||
# Complete value type
|
|
||||||
# Unfortunately ${COMP_WORDS[key_index]} fails on keys with spaces
|
|
||||||
local value_types='-string -data -integer -float -boolean -date -array -array-add -dict -dict-add'
|
|
||||||
local cur_type=$( defaults read-type $domain ${COMP_WORDS[key_index]} 2>/dev/null | sed -e 's/^Type is \(.*\)/-\1/' -e's/dictionary/dict/' | grep "^$cur" )
|
|
||||||
if [[ $cur_type ]]; then
|
|
||||||
COMPREPLY=( $cur_type )
|
|
||||||
else
|
|
||||||
COMPREPLY=( $( compgen -W "$value_types" -- $cur ) )
|
|
||||||
fi
|
|
||||||
elif [[ $((key_index+2)) -eq $COMP_CWORD ]]; then
|
|
||||||
# Complete value
|
|
||||||
# Unfortunately ${COMP_WORDS[key_index]} fails on keys with spaces
|
|
||||||
COMPREPLY=( $( defaults read $domain ${COMP_WORDS[key_index]} 2>/dev/null | grep -i "^${cur//\\/\\\\}" ) )
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
rename)
|
|
||||||
if [[ $key_index -eq $COMP_CWORD ]] ||
|
|
||||||
[[ $((key_index+1)) -eq $COMP_CWORD ]]; then
|
|
||||||
# Complete source and destination keys
|
|
||||||
local IFS=$'\n'
|
|
||||||
COMPREPLY=( $( echo "$keys" | grep -i "^${cur//\\/\\\\}" ) )
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
delete)
|
|
||||||
if [[ $key_index -eq $COMP_CWORD ]]; then
|
|
||||||
# Complete key
|
|
||||||
local IFS=$'\n'
|
|
||||||
COMPREPLY=( $( echo "$keys" | grep -i "^${cur//\\/\\\\}" ) )
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
complete -F _defaults -o default defaults
|
|
||||||
|
|
||||||
|
|
||||||
# This file is licensed under the BSD license, as follows:
|
|
||||||
#
|
|
||||||
# Copyright (c) 2006, Playhaus
|
|
||||||
# All rights reserved.
|
|
||||||
#
|
|
||||||
# Redistribution and use in source and binary forms, with or without
|
|
||||||
# modification, are permitted provided that the following conditions are met:
|
|
||||||
#
|
|
||||||
# * Redistributions of source code must retain the above copyright notice, this
|
|
||||||
# list of conditions and the following disclaimer.
|
|
||||||
# * Redistributions in binary form must reproduce the above copyright notice,
|
|
||||||
# this list of conditions and the following disclaimer in the documentation
|
|
||||||
# and/or other materials provided with the distribution.
|
|
||||||
# * Neither the name of the Playhaus nor the names of its contributors may be
|
|
||||||
# used to endorse or promote products derived from this software without
|
|
||||||
# specific prior written permission.
|
|
||||||
#
|
|
||||||
# This software is provided by the copyright holders and contributors "as is"
|
|
||||||
# and any express or implied warranties, including, but not limited to, the
|
|
||||||
# implied warranties of merchantability and fitness for a particular purpose are
|
|
||||||
# disclaimed. In no event shall the copyright owner or contributors be liable
|
|
||||||
# for any direct, indirect, incidental, special, exemplary, or consequential
|
|
||||||
# damages (including, but not limited to, procurement of substitute goods or
|
|
||||||
# services; loss of use, data, or profits; or business interruption) however
|
|
||||||
# caused and on any theory of liability, whether in contract, strict liability,
|
|
||||||
# or tort (including negligence or otherwise) arising in any way out of the use
|
|
||||||
# of this software, even if advised of the possibility of such damage.
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,22 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
function __dmidecode_completion() {
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
local prev=$(_get_pword)
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
local curr=$(_get_cword)
|
||||||
|
|
||||||
|
case $prev in
|
||||||
|
-s | --string | -t | --type)
|
||||||
|
OPTS=$(dmidecode "$prev" 2>&1 | grep -E '^ ' | sed 's/ *//g')
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$OPTS" -- "$curr"))
|
||||||
|
;;
|
||||||
|
dmidecode)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "-d --dev-mem -h --help -q --quiet -s --string -t --type -H --handle -u --dump{,-bin} --from-dump --no-sysfs --oem-string -V --version" -- "$curr"))
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
complete -F __dmidecode_completion dmidecode
|
||||||
|
|
@ -676,7 +676,7 @@ _docker_compose() {
|
||||||
done
|
done
|
||||||
|
|
||||||
local completions_func=_docker_compose_${command//-/_}
|
local completions_func=_docker_compose_${command//-/_}
|
||||||
declare -F $completions_func >/dev/null && $completions_func
|
_is_function $completions_func && $completions_func
|
||||||
|
|
||||||
eval "$previous_extglob_setting"
|
eval "$previous_extglob_setting"
|
||||||
return 0
|
return 0
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
about-completion "bash parameter completion for the dotnet CLI"
|
||||||
|
# see https://docs.microsoft.com/en-us/dotnet/core/tools/enable-tab-autocomplete#bash
|
||||||
|
|
||||||
|
function _dotnet_bash_complete() {
|
||||||
|
local cur="${COMP_WORDS[COMP_CWORD]}" IFS=$'\n'
|
||||||
|
local candidates
|
||||||
|
|
||||||
|
read -d '' -ra candidates < <(dotnet complete --position "${COMP_POINT}" "${COMP_LINE}" 2> /dev/null)
|
||||||
|
|
||||||
|
read -d '' -ra COMPREPLY < <(compgen -W "${candidates[*]:-}" -- "$cur")
|
||||||
|
}
|
||||||
|
|
||||||
|
complete -f -F _dotnet_bash_complete dotnet
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
#
|
#
|
||||||
# Bash completion support for Fabric (http://fabfile.org/)
|
# Bash completion support for Fabric (http://fabfile.org/)
|
||||||
#
|
#
|
||||||
|
|
@ -41,8 +41,8 @@ export FAB_COMPLETION_CACHED_TASKS_FILENAME=".fab_tasks~"
|
||||||
|
|
||||||
|
|
||||||
# Set command to get time of last file modification as seconds since Epoch
|
# Set command to get time of last file modification as seconds since Epoch
|
||||||
case `uname` in
|
case "$OSTYPE" in
|
||||||
Darwin|FreeBSD)
|
'darwin'*|'freebsd'*)
|
||||||
__FAB_COMPLETION_MTIME_COMMAND="stat -f '%m'"
|
__FAB_COMPLETION_MTIME_COMMAND="stat -f '%m'"
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
|
|
@ -91,7 +91,7 @@ function __fab_completion() {
|
||||||
-*)
|
-*)
|
||||||
if [[ -z "${__FAB_COMPLETION_LONG_OPT}" ]]; then
|
if [[ -z "${__FAB_COMPLETION_LONG_OPT}" ]]; then
|
||||||
export __FAB_COMPLETION_LONG_OPT=$(
|
export __FAB_COMPLETION_LONG_OPT=$(
|
||||||
fab --help | egrep -o "\-\-[A-Za-z_\-]+\=?" | sort -u)
|
fab --help | grep -E -o "\-\-[A-Za-z_\-]+\=?" | sort -u)
|
||||||
fi
|
fi
|
||||||
opts="${__FAB_COMPLETION_LONG_OPT}"
|
opts="${__FAB_COMPLETION_LONG_OPT}"
|
||||||
;;
|
;;
|
||||||
|
|
@ -101,7 +101,7 @@ function __fab_completion() {
|
||||||
# -*)
|
# -*)
|
||||||
# if [[ -z "${__FAB_COMPLETION_SHORT_OPT}" ]]; then
|
# if [[ -z "${__FAB_COMPLETION_SHORT_OPT}" ]]; then
|
||||||
# export __FAB_COMPLETION_SHORT_OPT=$(
|
# export __FAB_COMPLETION_SHORT_OPT=$(
|
||||||
# fab --help | egrep -o "^ +\-[A-Za-z_\]" | sort -u)
|
# fab --help | grep -E -o "^ +\-[A-Za-z_\]" | sort -u)
|
||||||
# fi
|
# fi
|
||||||
# opts="${__FAB_COMPLETION_SHORT_OPT}"
|
# opts="${__FAB_COMPLETION_SHORT_OPT}"
|
||||||
# ;;
|
# ;;
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
#!/usr/bin/bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
if _command_exists flutter; then
|
if _command_exists flutter; then
|
||||||
eval "$(flutter bash-completion)"
|
eval "$(flutter bash-completion)"
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,39 +1,42 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
|
#
|
||||||
# Only operate on MacOS since there are no linux paths
|
# Locate and load completions for `git`.
|
||||||
if [[ "$(uname -s)" != 'Darwin' ]] ; then
|
|
||||||
_log_warning "unsupported operating system - only 'Darwin' is supported"
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Make sure git is installed
|
# Make sure git is installed
|
||||||
_command_exists git || return 0
|
_command_exists git || return
|
||||||
|
|
||||||
# Don't handle completion if it's already managed
|
# Don't handle completion if it's already managed
|
||||||
if complete -p git &>/dev/null ; then
|
if complete -p git &> /dev/null; then
|
||||||
_log_warning "completion already loaded - this usually means it is safe to stop using this completion"
|
_log_warning "completion already loaded - this usually means it is safe to stop using this completion"
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
_git_bash_completion_found=false
|
_git_bash_completion_xcrun_git=
|
||||||
|
if _command_exists xcrun; then
|
||||||
|
_git_bash_completion_xcrun_git="$(xcrun --find git)"
|
||||||
|
fi
|
||||||
_git_bash_completion_paths=(
|
_git_bash_completion_paths=(
|
||||||
# MacOS non-system locations
|
# Standard locations
|
||||||
'/Library/Developer/CommandLineTools/usr/share/git-core/git-completion.bash'
|
"${GIT_EXE%/*}/../share/git-core/git-completion.bash"
|
||||||
'/Applications/Xcode.app/Contents/Developer/usr/share/git-core/git-completion.bash'
|
"${GIT_EXE%/*}/../share/git-core/contrib/completion/git-completion.bash"
|
||||||
|
"${GIT_EXE%/*}/../etc/bash_completion.d/git-completion.bash"
|
||||||
|
# MacOS non-system locations
|
||||||
|
"${_git_bash_completion_xcrun_git%/bin/git}/share/git-core/git-completion.bash"
|
||||||
)
|
)
|
||||||
|
|
||||||
# Load the first completion file found
|
# Load the first completion file found
|
||||||
for _comp_path in "${_git_bash_completion_paths[@]}" ; do
|
_git_bash_completion_found=false
|
||||||
if [ -r "$_comp_path" ] ; then
|
for _comp_path in "${_git_bash_completion_paths[@]}"; do
|
||||||
_git_bash_completion_found=true
|
if [[ -r "$_comp_path" ]]; then
|
||||||
source "$_comp_path"
|
_git_bash_completion_found=true
|
||||||
break
|
# shellcheck disable=SC1090 # don't follow
|
||||||
fi
|
source "$_comp_path"
|
||||||
|
break
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
# Cleanup
|
# Cleanup
|
||||||
if [[ "${_git_bash_completion_found}" == false ]]; then
|
if [[ "${_git_bash_completion_found}" == false ]]; then
|
||||||
_log_warning "no completion files found - please try enabling the 'system' completion instead."
|
_log_warning "no completion files found - please try enabling the 'system' completion instead."
|
||||||
fi
|
fi
|
||||||
unset _git_bash_completion_paths
|
unset "${!_git_bash_completion@}"
|
||||||
unset _git_bash_completion_found
|
|
||||||
|
|
|
||||||
|
|
@ -172,6 +172,7 @@ __git_flow_list_hotfixes ()
|
||||||
}
|
}
|
||||||
|
|
||||||
# temporarily wrap __git_find_on_cmdline() for backwards compatibility
|
# temporarily wrap __git_find_on_cmdline() for backwards compatibility
|
||||||
if [ -z "`type -t __git_find_subcommand`" ]; then
|
if ! _command_exists __git_find_subcommand
|
||||||
|
then
|
||||||
alias __git_find_subcommand=__git_find_on_cmdline
|
alias __git_find_subcommand=__git_find_on_cmdline
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -505,6 +505,7 @@ __git_flow_list_branches ()
|
||||||
}
|
}
|
||||||
|
|
||||||
# alias __git_find_on_cmdline for backwards compatibility
|
# alias __git_find_on_cmdline for backwards compatibility
|
||||||
if [ -z "`type -t __git_find_on_cmdline`" ]; then
|
if ! _command_exists __git_find_on_cmdline
|
||||||
|
then
|
||||||
alias __git_find_on_cmdline=__git_find_subcommand
|
alias __git_find_on_cmdline=__git_find_subcommand
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
|
||||||
# Copyright (c) 2017 Eric Wendelin
|
# Copyright (c) 2017 Eric Wendelin
|
||||||
|
|
||||||
# Permission is hereby granted, free of charge, to any person obtaining a copy of
|
# Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||||
|
|
@ -22,17 +24,9 @@
|
||||||
# Avoid inaccurate completions for subproject tasks
|
# Avoid inaccurate completions for subproject tasks
|
||||||
COMP_WORDBREAKS=$(echo "$COMP_WORDBREAKS" | sed -e 's/://g')
|
COMP_WORDBREAKS=$(echo "$COMP_WORDBREAKS" | sed -e 's/://g')
|
||||||
|
|
||||||
__gradle-set-project-root-dir() {
|
function __gradle-set-project-root-dir() {
|
||||||
local dir=`pwd`
|
project_root_dir="$(_bash-it-find-in-ancestor "settings.gradle" "gradlew")"
|
||||||
project_root_dir=`pwd`
|
return "$?"
|
||||||
while [[ $dir != '/' ]]; do
|
|
||||||
if [[ -f "$dir/settings.gradle" || -f "$dir/gradlew" ]]; then
|
|
||||||
project_root_dir=$dir
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
dir="$(dirname "$dir")"
|
|
||||||
done
|
|
||||||
return 1
|
|
||||||
}
|
}
|
||||||
|
|
||||||
__gradle-init-cache-dir() {
|
__gradle-init-cache-dir() {
|
||||||
|
|
@ -58,9 +52,9 @@ __gradle-set-cache-name() {
|
||||||
|
|
||||||
__gradle-set-files-checksum() {
|
__gradle-set-files-checksum() {
|
||||||
# Cache MD5 sum of all Gradle scripts and modified timestamps
|
# Cache MD5 sum of all Gradle scripts and modified timestamps
|
||||||
if builtin command -v md5 > /dev/null; then
|
if _command_exists md5; then
|
||||||
gradle_files_checksum=$(md5 -q -s "$(cat "$cache_dir/$cache_name" | xargs ls -o 2>/dev/null)")
|
gradle_files_checksum=$(md5 -q -s "$(cat "$cache_dir/$cache_name" | xargs ls -o 2>/dev/null)")
|
||||||
elif builtin command -v md5sum > /dev/null; then
|
elif _command_exists md5sum; then
|
||||||
gradle_files_checksum=$(cat "$cache_dir/$cache_name" | xargs ls -o 2>/dev/null | md5sum | awk '{print $1}')
|
gradle_files_checksum=$(cat "$cache_dir/$cache_name" | xargs ls -o 2>/dev/null | md5sum | awk '{print $1}')
|
||||||
else
|
else
|
||||||
echo "Cannot generate completions as neither md5 nor md5sum exist on \$PATH"
|
echo "Cannot generate completions as neither md5 nor md5sum exist on \$PATH"
|
||||||
|
|
@ -74,7 +68,7 @@ __gradle-generate-script-cache() {
|
||||||
|
|
||||||
if [[ ! $(find $cache_dir/$cache_name -mmin -$cache_ttl_mins 2>/dev/null) ]]; then
|
if [[ ! $(find $cache_dir/$cache_name -mmin -$cache_ttl_mins 2>/dev/null) ]]; then
|
||||||
# Cache all Gradle scripts
|
# Cache all Gradle scripts
|
||||||
local gradle_build_scripts=$(find $project_root_dir -type f -name "*.gradle" -o -name "*.gradle.kts" 2>/dev/null | egrep -v "$script_exclude_pattern")
|
local gradle_build_scripts=$(find $project_root_dir -type f -name "*.gradle" -o -name "*.gradle.kts" 2>/dev/null | grep -E -v "$script_exclude_pattern")
|
||||||
printf "%s\n" "${gradle_build_scripts[@]}" > $cache_dir/$cache_name
|
printf "%s\n" "${gradle_build_scripts[@]}" > $cache_dir/$cache_name
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -23,12 +23,12 @@
|
||||||
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
|
|
||||||
# If there is no git tab completion, but we have the _completion loader try to load it
|
# If there is no git tab completion, but we have the _completion loader try to load it
|
||||||
if ! declare -F _git > /dev/null && declare -F _completion_loader > /dev/null; then
|
if ! _is_function _git && _is_function _completion_loader; then
|
||||||
_completion_loader git
|
_completion_loader git
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Check that git tab completion is available and we haven't already set up completion
|
# Check that git tab completion is available and we haven't already set up completion
|
||||||
if declare -F _git > /dev/null && ! declare -F __git_list_all_commands_without_hub > /dev/null; then
|
if _is_function _git && ! _is_function __git_list_all_commands_without_hub; then
|
||||||
# Duplicate and rename the 'list_all_commands' function
|
# Duplicate and rename the 'list_all_commands' function
|
||||||
eval "$(declare -f __git_list_all_commands | \
|
eval "$(declare -f __git_list_all_commands | \
|
||||||
sed 's/__git_list_all_commands/__git_list_all_commands_without_hub/')"
|
sed 's/__git_list_all_commands/__git_list_all_commands_without_hub/')"
|
||||||
|
|
@ -227,7 +227,7 @@ EOF
|
||||||
((c++))
|
((c++))
|
||||||
done
|
done
|
||||||
if [ -z "$name" ]; then
|
if [ -z "$name" ]; then
|
||||||
repo=$(basename "$(pwd)")
|
repo="$(basename "${PWD}")"
|
||||||
fi
|
fi
|
||||||
case "$prev" in
|
case "$prev" in
|
||||||
-d|-h)
|
-d|-h)
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,4 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
about-completion "jboss5 completion"
|
||||||
|
# shellcheck disable=SC1090
|
||||||
|
source "${BASH_IT}"/vendor/github.com/rparree/jboss-bash-completion/jboss5
|
||||||
|
|
@ -1,160 +1,4 @@
|
||||||
# Completions for JBoss Application Server 7 (EAP 6)
|
# shellcheck shell=bash
|
||||||
# VERSION: 0.6
|
about-completion "jboss7 completion"
|
||||||
# DATE: 2012-10-30
|
# shellcheck disable=SC1090
|
||||||
# rparree-at-edc4it-dot-com
|
source "${BASH_IT}"/vendor/github.com/rparree/jboss-bash-completion/jboss7
|
||||||
|
|
||||||
# MIT License
|
|
||||||
|
|
||||||
# Copyright (c) 2020 Raphael Parree
|
|
||||||
|
|
||||||
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
||||||
# of this software and associated documentation files (the "Software"), to deal
|
|
||||||
# in the Software without restriction, including without limitation the rights
|
|
||||||
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
||||||
# copies of the Software, and to permit persons to whom the Software is
|
|
||||||
# furnished to do so, subject to the following conditions:
|
|
||||||
|
|
||||||
# The above copyright notice and this permission notice shall be included in all
|
|
||||||
# copies or substantial portions of the Software.
|
|
||||||
|
|
||||||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
||||||
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
||||||
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
||||||
# SOFTWARE.
|
|
||||||
|
|
||||||
_serverProfiles(){
|
|
||||||
if [[ $COMP_WORDS == *standalone.sh* ]]
|
|
||||||
then
|
|
||||||
serverdir="../standalone/configuration/"
|
|
||||||
else
|
|
||||||
# assume is domain.sh
|
|
||||||
serverdir="../domain/configuration/"
|
|
||||||
fi
|
|
||||||
|
|
||||||
for i in ${!COMP_WORDS[*]}
|
|
||||||
do
|
|
||||||
if [[ "${COMP_WORDS[i]}" == "-Djboss.server.base.dir" || "${COMP_WORDS[i]}" == "-Djboss.domain.base.dir" ]]; then
|
|
||||||
serverdir="${COMP_WORDS[i+2]}/configuration"
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
if [ -d "${serverdir}" ]
|
|
||||||
then
|
|
||||||
|
|
||||||
IFS=$'\n' tmp="$(ls "${serverdir}" | grep xml)"
|
|
||||||
local fls="${tmp[@]// /\ }"
|
|
||||||
unset IFS
|
|
||||||
COMPREPLY=( $(compgen -W "${fls} initial boot last v" -- "$cur" ))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_bindingAddress(){
|
|
||||||
# from /etc/bash_completion.d/ssh
|
|
||||||
COMPREPLY=( "${COMPREPLY[@]}" $( compgen -W \
|
|
||||||
"0.0.0.0 $( PATH="$PATH:/sbin" ifconfig -a | \
|
|
||||||
sed -ne 's/.*addr:\([^[:space:]]*\).*/\1/p' \
|
|
||||||
-ne 's/.*inet[[:space:]]\{1,\}\([^[:space:]]*\).*/\1/p' )" \
|
|
||||||
-- "$cur" ) )
|
|
||||||
}
|
|
||||||
|
|
||||||
_jboss(){
|
|
||||||
|
|
||||||
local cur prev words cword
|
|
||||||
COMPREPLY=()
|
|
||||||
_get_comp_words_by_ref -n = cur prev words cword
|
|
||||||
|
|
||||||
case $cur in
|
|
||||||
|
|
||||||
-Djboss.socket.binding.port-offset=*)
|
|
||||||
cur=${cur#*=}
|
|
||||||
#static list of common bindings sets
|
|
||||||
local bindings="100 200 300 400 10000 20000 30000 40000"
|
|
||||||
COMPREPLY=( $(compgen -W "${bindings}" -- ${cur}) )
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
-Djboss.default.jgroups.stack=*)
|
|
||||||
cur=${cur#*=}
|
|
||||||
#static list of standard JGroups stacks
|
|
||||||
local stacks="udp udp-async udp-sync tcp tcp-sync"
|
|
||||||
COMPREPLY=( $(compgen -W "${stacks}" -- ${cur}) )
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
|
|
||||||
-Dorg.jboss.ejb3.remoting.IsLocalInterceptor.passByRef=*|-Dcom.sun.management.jmxremote.authenticate=*|-Dcom.sun.management.jmxremote.ssl=*)
|
|
||||||
cur=${cur#*=}
|
|
||||||
local booleans="true false"
|
|
||||||
COMPREPLY=( $(compgen -W "${booleans}" -- ${cur}) )
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
|
|
||||||
-Djboss.server.base.dir=*|-Djboss.home.dir=*|-Djboss.domain.base.dir=*)
|
|
||||||
cur=${cur#*=}
|
|
||||||
_filedir -d
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
|
|
||||||
-Djboss.domain.master.address=*|-Djboss.bind.address*=*)
|
|
||||||
cur=${cur#*=}
|
|
||||||
_bindingAddress
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
--server-config=*|-c=|--host-config=*)
|
|
||||||
cur=${cur#*=}
|
|
||||||
_serverProfiles
|
|
||||||
return 0
|
|
||||||
|
|
||||||
|
|
||||||
esac
|
|
||||||
|
|
||||||
|
|
||||||
case $prev in
|
|
||||||
-u)
|
|
||||||
# a few from RFC 2365 IPv4 Local Scope ()
|
|
||||||
local addresses="239.255.0.1 239.255.0.2 239.255.0.3"
|
|
||||||
COMPREPLY=( $(compgen -W "${addresses}" -- ${cur}) )
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
-b*)
|
|
||||||
_bindingAddress
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
-c)
|
|
||||||
_serverProfiles
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
# *** from jboss5 ********************
|
|
||||||
# *** -modulepath -c -m -g -l -d -p -n -B -L -C -Djboss.platform.mbeanserver -Djboss.server.base.directory
|
|
||||||
# *** -Djboss.Domain -Djboss.modcluster.proxyList -Djboss.jvmRoute -Djboss.default.jgroups.stack -Dorg.jboss.ejb3.remoting.IsLocalInterceptor.passByRef -Djboss.platform.mbeanserver -Dcom.sun.management.jmxremote.port -Dcom.sun.management.jmxremote.ssl
|
|
||||||
# *************************************
|
|
||||||
|
|
||||||
# standard commands for standalone and domain mode
|
|
||||||
local commandsWithoutEqualSign='-b -bmanagement -bunsecure -bpublic --admin-only -h -help -u -version -V -v'
|
|
||||||
local commandsWithEqualSign='-P -Djboss.node.name -Djboss.home.dir -Djboss.socket.binding.port-offset -Djboss.bind.address.management -Djboss.bind.address -Djboss.bind.address.unsecure'
|
|
||||||
|
|
||||||
if [[ $COMP_WORDS == *standalone.sh* ]]
|
|
||||||
then
|
|
||||||
commandsWithoutEqualSign="${commandsWithoutEqualSign} -c"
|
|
||||||
commandsWithEqualSign="${commandsWithEqualSign} --server-config -Djboss.server.base.dir -c"
|
|
||||||
else
|
|
||||||
# assume is domain.sh
|
|
||||||
commandsWithoutEqualSign="${commandsWithoutEqualSign} --backup --cached-dc"
|
|
||||||
commandsWithEqualSign="${commandsWithEqualSign} -Djboss.domain.master.address --host-config -Djboss.domain.master.port -Djboss.domain.base.dir "
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
COMPREPLY=( $( compgen -W "$commandsWithoutEqualSign" -- "$cur" )
|
|
||||||
$( compgen -W "$commandsWithEqualSign" -S '=' -- "$cur" ) )
|
|
||||||
return 0
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
complete -o nospace -F _jboss standalone.sh
|
|
||||||
complete -o nospace -F _jboss domain.sh
|
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,7 @@ _KAC_is_file_newer_than() {
|
||||||
_KAC_regen_cache() {
|
_KAC_regen_cache() {
|
||||||
local CACHE_NAME=$1
|
local CACHE_NAME=$1
|
||||||
local CACHE_PATH="$_KNIFE_AUTOCOMPLETE_CACHE_DIR/$CACHE_NAME"
|
local CACHE_PATH="$_KNIFE_AUTOCOMPLETE_CACHE_DIR/$CACHE_NAME"
|
||||||
|
# shellcheck disable=SC2155
|
||||||
local TMP_FILE=$(mktemp "$_KAC_CACHE_TMP_DIR/$CACHE_NAME.XXXX")
|
local TMP_FILE=$(mktemp "$_KAC_CACHE_TMP_DIR/$CACHE_NAME.XXXX")
|
||||||
shift 1
|
shift 1
|
||||||
# discard the temp file if it's empty AND the previous command didn't exit successfully, but still mark the cache as updated
|
# discard the temp file if it's empty AND the previous command didn't exit successfully, but still mark the cache as updated
|
||||||
|
|
@ -54,18 +55,19 @@ _KAC_regen_cache() {
|
||||||
|
|
||||||
# cached files can't have spaces in their names
|
# cached files can't have spaces in their names
|
||||||
_KAC_get_cache_name_from_command() {
|
_KAC_get_cache_name_from_command() {
|
||||||
echo "${@/ /_SPACE_}"
|
echo "${@// /_SPACE_}"
|
||||||
}
|
}
|
||||||
|
|
||||||
# the reverse operation from the function above
|
# the reverse operation from the function above
|
||||||
_KAC_get_command_from_cache_name() {
|
_KAC_get_command_from_cache_name() {
|
||||||
echo "${@/_SPACE_/ }"
|
echo "${@//_SPACE_/ }"
|
||||||
}
|
}
|
||||||
|
|
||||||
# given a command as argument, it fetches the cache for that command if it can find it
|
# given a command as argument, it fetches the cache for that command if it can find it
|
||||||
# otherwise it waits for the cache to be generated
|
# otherwise it waits for the cache to be generated
|
||||||
# in either case, it regenerates the cache, and sets the _KAC_CACHE_PATH env variable
|
# in either case, it regenerates the cache, and sets the _KAC_CACHE_PATH env variable
|
||||||
# for obvious reason, do NOT call that in a sub-shell (in particular, no piping)
|
# for obvious reason, do NOT call that in a sub-shell (in particular, no piping)
|
||||||
|
# shellcheck disable=SC2155
|
||||||
_KAC_get_and_regen_cache() {
|
_KAC_get_and_regen_cache() {
|
||||||
# the cache name can't have space in it
|
# the cache name can't have space in it
|
||||||
local CACHE_NAME=$(_KAC_get_cache_name_from_command "$@")
|
local CACHE_NAME=$(_KAC_get_cache_name_from_command "$@")
|
||||||
|
|
@ -100,7 +102,7 @@ _KAC_clean_cache() {
|
||||||
|
|
||||||
# perform a cache cleaning when loading this file
|
# perform a cache cleaning when loading this file
|
||||||
# On big systems this could baloon up to a 30 second run or more, so not enabling by default.
|
# On big systems this could baloon up to a 30 second run or more, so not enabling by default.
|
||||||
[[ "${KNIFE_CACHE_CLEAN}" ]] && _KAC_clean_cache
|
[[ -n "${KNIFE_CACHE_CLEAN}" ]] && _KAC_clean_cache
|
||||||
|
|
||||||
#####################################
|
#####################################
|
||||||
### End of cache helper functions ###
|
### End of cache helper functions ###
|
||||||
|
|
@ -118,7 +120,7 @@ _KAC_get_current_base_command() {
|
||||||
local PREVIOUS="knife"
|
local PREVIOUS="knife"
|
||||||
local I=1
|
local I=1
|
||||||
local CURRENT
|
local CURRENT
|
||||||
while [ $I -le "$COMP_CWORD" ]; do
|
while [[ "${I}" -le "${COMP_CWORD}" ]]; do
|
||||||
# command words are all lower-case
|
# command words are all lower-case
|
||||||
echo "${COMP_WORDS[$I]}" | grep -E "^[a-z]+$" > /dev/null || break
|
echo "${COMP_WORDS[$I]}" | grep -E "^[a-z]+$" > /dev/null || break
|
||||||
CURRENT="$PREVIOUS ${COMP_WORDS[$I]}"
|
CURRENT="$PREVIOUS ${COMP_WORDS[$I]}"
|
||||||
|
|
@ -127,12 +129,13 @@ _KAC_get_current_base_command() {
|
||||||
I=$((I + 1))
|
I=$((I + 1))
|
||||||
done
|
done
|
||||||
_KAC_CURRENT_COMMAND=$PREVIOUS
|
_KAC_CURRENT_COMMAND=$PREVIOUS
|
||||||
[ $I -le "$COMP_CWORD" ] && _KAC_CURRENT_COMMAND_NB_WORDS=$I
|
[[ "${I}" -le "${COMP_CWORD}" ]] && _KAC_CURRENT_COMMAND_NB_WORDS="${I}"
|
||||||
}
|
}
|
||||||
|
|
||||||
# searches the position of the currently completed argument in the current base command
|
# searches the position of the currently completed argument in the current base command
|
||||||
# (i.e. handles "plural" arguments such as knife cookbook upload cookbook1 cookbook2 and so on...)
|
# (i.e. handles "plural" arguments such as knife cookbook upload cookbook1 cookbook2 and so on...)
|
||||||
# assumes the current base command is complete
|
# assumes the current base command is complete
|
||||||
|
# shellcheck disable=SC2155
|
||||||
_KAC_get_current_arg_position() {
|
_KAC_get_current_arg_position() {
|
||||||
local CURRENT_ARG_POS=$((_KAC_CURRENT_COMMAND_NB_WORDS + 1))
|
local CURRENT_ARG_POS=$((_KAC_CURRENT_COMMAND_NB_WORDS + 1))
|
||||||
local COMPLETE_COMMAND=$(grep -E "^$_KAC_CURRENT_COMMAND" "$_KAC_CACHE_PATH")
|
local COMPLETE_COMMAND=$(grep -E "^$_KAC_CURRENT_COMMAND" "$_KAC_CACHE_PATH")
|
||||||
|
|
@ -150,10 +153,11 @@ _KAC_get_current_arg_position() {
|
||||||
_knife() {
|
_knife() {
|
||||||
_KAC_get_and_regen_cache _KAC_knife_commands
|
_KAC_get_and_regen_cache _KAC_knife_commands
|
||||||
local RAW_LIST ITEM REGEN_CMD ARG_POSITION
|
local RAW_LIST ITEM REGEN_CMD ARG_POSITION
|
||||||
|
# shellcheck disable=SC2034
|
||||||
COMREPLY=()
|
COMREPLY=()
|
||||||
# get correct command & arg pos
|
# get correct command & arg pos
|
||||||
_KAC_get_current_base_command && ARG_POSITION=$(_KAC_get_current_arg_position) || ARG_POSITION=$((COMP_CWORD + 1))
|
_KAC_get_current_base_command && ARG_POSITION=$(_KAC_get_current_arg_position) || ARG_POSITION=$((COMP_CWORD + 1))
|
||||||
RAW_LIST=$(grep -E "^$_KAC_CURRENT_COMMAND" "$_KAC_CACHE_PATH" | cut -d ' ' -f $ARG_POSITION | uniq)
|
RAW_LIST=$(grep -E "^${_KAC_CURRENT_COMMAND}" "${_KAC_CACHE_PATH}" | cut -d ' ' -f "${ARG_POSITION}" | uniq)
|
||||||
|
|
||||||
# we need to process that raw list a bit, most notably for placeholders
|
# we need to process that raw list a bit, most notably for placeholders
|
||||||
# NOTE: I chose to explicitely fetch & cache _certain_ informations for the server (cookbooks & node names, etc)
|
# NOTE: I chose to explicitely fetch & cache _certain_ informations for the server (cookbooks & node names, etc)
|
||||||
|
|
|
||||||
|
|
@ -1,15 +1,16 @@
|
||||||
#!/usr/bin/bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
if command -v laravel > /dev/null; then
|
_command_exists laravel || return
|
||||||
__laravel_completion() {
|
|
||||||
local OPTS=("-h --help -q --quiet --ansi --no-ansi -n --no-interaction -v -vv -vvv --verbose help list new")
|
|
||||||
COMPREPLY=()
|
|
||||||
for _opt_ in ${OPTS[@]}; do
|
|
||||||
if [[ "$_opt_" == "$2"* ]]; then
|
|
||||||
COMPREPLY+=("$_opt_")
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
complete -F __laravel_completion laravel
|
function __laravel_completion() {
|
||||||
fi
|
local OPTS=('-h' '--help' '-q' '--quiet' '--ansi' '--no-ansi' '-n' '--no-interaction' '-v' '-vv' '-vvv' '--verbose' 'help' 'list' 'new')
|
||||||
|
local _opt_
|
||||||
|
COMPREPLY=()
|
||||||
|
for _opt_ in "${OPTS[@]}"; do
|
||||||
|
if [[ "$_opt_" == "$2"* ]]; then
|
||||||
|
COMPREPLY+=("$_opt_")
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
complete -F __laravel_completion laravel
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
|
||||||
# Bash completion for Makefile
|
# Bash completion for Makefile
|
||||||
# Loosely adapted from http://stackoverflow.com/a/38415982/1472048
|
# Loosely adapted from http://stackoverflow.com/a/38415982/1472048
|
||||||
|
|
||||||
|
|
@ -17,7 +19,7 @@ _makecomplete() {
|
||||||
for f in "${files[@]}" ; do
|
for f in "${files[@]}" ; do
|
||||||
while IFS='' read -r line ; do
|
while IFS='' read -r line ; do
|
||||||
targets+=("$line")
|
targets+=("$line")
|
||||||
done < <(grep -oE '^[a-zA-Z0-9_-]+:([^=]|$)' "$f" | cut -d':' -f1)
|
done < <(grep -E -o '^[a-zA-Z0-9_-]+:([^=]|$)' "$f" | cut -d':' -f1)
|
||||||
done
|
done
|
||||||
|
|
||||||
[ "${#targets[@]}" -eq 0 ] && return 0
|
[ "${#targets[@]}" -eq 0 ] && return 0
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,47 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
__ngrok_completion() {
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
local prev=$(_get_pword)
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
local curr=$(_get_cword)
|
||||||
|
|
||||||
|
local BASE_NO_CONF="--log --log-format --log-level --help"
|
||||||
|
local BASE="--config $BASE_NO_CONF"
|
||||||
|
local DEFAULT="$BASE --authtoken --region"
|
||||||
|
|
||||||
|
case $prev in
|
||||||
|
authtoken)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$BASE" -- "$curr"))
|
||||||
|
;;
|
||||||
|
http)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$DEFAULT --auth --bind-tls --host-header --hostname --inspect --subdomain" -- "$curr"))
|
||||||
|
;;
|
||||||
|
start)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$DEFAULT --all --none" -- "$curr"))
|
||||||
|
;;
|
||||||
|
tcp)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$DEFAULT --remote-addr" -- "$curr"))
|
||||||
|
;;
|
||||||
|
tls)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$DEFAULT --client-cas --crt --hostname --key --subdomain" -- "$curr"))
|
||||||
|
;;
|
||||||
|
update)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "$BASE_NO_CONF --channel" -- "$curr"))
|
||||||
|
;;
|
||||||
|
ngrok)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "authtoken credits http start tcp tls update version help" -- "$curr"))
|
||||||
|
;;
|
||||||
|
*) ;;
|
||||||
|
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
complete -F __ngrok_completion ngrok
|
||||||
|
|
@ -1,7 +1,9 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
function __notify-send_completions() {
|
function __notify-send_completions() {
|
||||||
|
# shellcheck disable=SC2155
|
||||||
local curr=$(_get_cword)
|
local curr=$(_get_cword)
|
||||||
|
# shellcheck disable=SC2155
|
||||||
local prev=$(_get_pword)
|
local prev=$(_get_pword)
|
||||||
|
|
||||||
case $prev in
|
case $prev in
|
||||||
|
|
|
||||||
|
|
@ -1 +1,6 @@
|
||||||
[[ -x "$(which pew)" ]] && source "$(pew shell_config)"
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
if _command_exists pew
|
||||||
|
then
|
||||||
|
source "$(pew shell_config)"
|
||||||
|
fi
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,15 @@
|
||||||
# If the pip package is installed within virtual environments, say, python managed by pyenv,
|
# If the pip package is installed within virtual environments, say, python managed by pyenv,
|
||||||
# you should first initialize the corresponding environment.
|
# you should first initialize the corresponding environment.
|
||||||
# So that pip is in the system's path.
|
# So that pip is in the system's path.
|
||||||
if _command_exists pip; then
|
_command_exists pip || return
|
||||||
eval "$(pip completion --bash)"
|
|
||||||
fi
|
function __bash_it_complete_pip() {
|
||||||
|
if _command_exists _pip_completion; then
|
||||||
|
complete -o default -F _pip_completion pip
|
||||||
|
_pip_completion "$@"
|
||||||
|
else
|
||||||
|
eval "$(pip completion --bash)"
|
||||||
|
_pip_completion "$@"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
complete -o default -F __bash_it_complete_pip pip
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,15 @@
|
||||||
# If the pip package is installed within virtual environments, say, python managed by pyenv,
|
# If the pip package is installed within virtual environments, say, python managed by pyenv,
|
||||||
# you should first initialize the corresponding environment.
|
# you should first initialize the corresponding environment.
|
||||||
# So that pip3 is in the system's path.
|
# So that pip3 is in the system's path.
|
||||||
if _command_exists pip3; then
|
_command_exists pip3 || return
|
||||||
eval "$(pip3 completion --bash)"
|
|
||||||
fi
|
function __bash_it_complete_pip3() {
|
||||||
|
if _command_exists _pip_completion; then
|
||||||
|
complete -o default -F _pip_completion pip3
|
||||||
|
_pip_completion "$@"
|
||||||
|
else
|
||||||
|
eval "$(pip3 completion --bash)"
|
||||||
|
_pip_completion "$@"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
complete -o default -F __bash_it_complete_pip3 pip3
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
if _command_exists pipenv; then
|
if _command_exists pipenv; then
|
||||||
eval "$(pipenv --completion)"
|
eval "$(_PIPENV_COMPLETE=bash_source pipenv)"
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ _is_function _rl_enabled ||
|
||||||
_pj() {
|
_pj() {
|
||||||
_is_function _init_completion || return
|
_is_function _init_completion || return
|
||||||
_is_function _rl_enabled || return
|
_is_function _rl_enabled || return
|
||||||
[ -n "$PROJECT_PATHS" ] || return
|
[ -n "$BASH_IT_PROJECT_PATHS" ] || return
|
||||||
shift
|
shift
|
||||||
[ "$1" == "open" ] && shift
|
[ "$1" == "open" ] && shift
|
||||||
|
|
||||||
|
|
@ -21,7 +21,7 @@ _pj() {
|
||||||
local -r mark_dirs=$(_rl_enabled mark-directories && echo y)
|
local -r mark_dirs=$(_rl_enabled mark-directories && echo y)
|
||||||
local -r mark_symdirs=$(_rl_enabled mark-symlinked-directories && echo y)
|
local -r mark_symdirs=$(_rl_enabled mark-symlinked-directories && echo y)
|
||||||
|
|
||||||
for i in ${PROJECT_PATHS//:/$'\n'}; do
|
for i in ${BASH_IT_PROJECT_PATHS//:/$'\n'}; do
|
||||||
# create an array of matched subdirs
|
# create an array of matched subdirs
|
||||||
k="${#COMPREPLY[@]}"
|
k="${#COMPREPLY[@]}"
|
||||||
for j in $( compgen -d $i/$cur ); do
|
for j in $( compgen -d $i/$cur ); do
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,9 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
_sdkman_complete() {
|
|
||||||
|
function _sdkman_complete() {
|
||||||
local CANDIDATES
|
local CANDIDATES
|
||||||
local CANDIDATE_VERSIONS
|
local CANDIDATE_VERSIONS
|
||||||
|
local SDKMAN_CANDIDATES_CSV="${SDKMAN_CANDIDATES_CSV:-}"
|
||||||
|
|
||||||
COMPREPLY=()
|
COMPREPLY=()
|
||||||
|
|
||||||
|
|
@ -10,7 +12,7 @@ _sdkman_complete() {
|
||||||
elif [ "$COMP_CWORD" -eq 2 ]; then
|
elif [ "$COMP_CWORD" -eq 2 ]; then
|
||||||
case "${COMP_WORDS[COMP_CWORD - 1]}" in
|
case "${COMP_WORDS[COMP_CWORD - 1]}" in
|
||||||
"install" | "i" | "uninstall" | "rm" | "list" | "ls" | "use" | "u" | "default" | "d" | "home" | "h" | "current" | "c" | "upgrade" | "ug")
|
"install" | "i" | "uninstall" | "rm" | "list" | "ls" | "use" | "u" | "default" | "d" | "home" | "h" | "current" | "c" | "upgrade" | "ug")
|
||||||
CANDIDATES=$(echo "${SDKMAN_CANDIDATES_CSV}" | tr ',' ' ')
|
CANDIDATES="${SDKMAN_CANDIDATES_CSV//,/${IFS:0:1}}"
|
||||||
mapfile -t COMPREPLY < <(compgen -W "$CANDIDATES" -- "${COMP_WORDS[COMP_CWORD]}")
|
mapfile -t COMPREPLY < <(compgen -W "$CANDIDATES" -- "${COMP_WORDS[COMP_CWORD]}")
|
||||||
;;
|
;;
|
||||||
"env")
|
"env")
|
||||||
|
|
@ -46,17 +48,17 @@ _sdkman_complete() {
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
_sdkman_candidate_local_versions() {
|
function _sdkman_candidate_local_versions() {
|
||||||
|
|
||||||
CANDIDATE_VERSIONS=$(__sdkman_cleanup_local_versions "$1")
|
CANDIDATE_VERSIONS=$(__sdkman_cleanup_local_versions "$1")
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_sdkman_candidate_all_versions() {
|
function _sdkman_candidate_all_versions() {
|
||||||
|
|
||||||
candidate="$1"
|
candidate="$1"
|
||||||
CANDIDATE_LOCAL_VERSIONS=$(__sdkman_cleanup_local_versions "$candidate")
|
CANDIDATE_LOCAL_VERSIONS=$(__sdkman_cleanup_local_versions "$candidate")
|
||||||
if [ "$SDKMAN_OFFLINE_MODE" = "true" ]; then
|
if [[ "${SDKMAN_OFFLINE_MODE:-false}" == "true" ]]; then
|
||||||
CANDIDATE_VERSIONS=$CANDIDATE_LOCAL_VERSIONS
|
CANDIDATE_VERSIONS=$CANDIDATE_LOCAL_VERSIONS
|
||||||
else
|
else
|
||||||
# sdkman has a specific output format for Java candidate since
|
# sdkman has a specific output format for Java candidate since
|
||||||
|
|
@ -70,12 +72,12 @@ _sdkman_candidate_all_versions() {
|
||||||
# "+" - local version
|
# "+" - local version
|
||||||
# "*" - installed
|
# "*" - installed
|
||||||
# ">" - currently in use
|
# ">" - currently in use
|
||||||
CANDIDATE_VERSIONS="$(echo "$CANDIDATE_ONLINE_VERSIONS $CANDIDATE_LOCAL_VERSIONS" | tr ' ' '\n' | grep -v -e '^[[:space:]|\*|\>|\+]*$' | sort | uniq -u) "
|
CANDIDATE_VERSIONS="$(echo "$CANDIDATE_ONLINE_VERSIONS $CANDIDATE_LOCAL_VERSIONS" | tr ' ' '\n' | grep -v -e '^[[:space:]|\*|\>|\+]*$' | sort -u) "
|
||||||
fi
|
fi
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
__sdkman_cleanup_local_versions() {
|
function __sdkman_cleanup_local_versions() {
|
||||||
|
|
||||||
__sdkman_build_version_csv "$1" | tr ',' ' '
|
__sdkman_build_version_csv "$1" | tr ',' ' '
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,21 +1,22 @@
|
||||||
#!/bin/bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
# ---------------------------------------------------------------------------+
|
# ---------------------------------------------------------------------------+
|
||||||
# |
|
# |
|
||||||
# Thanks to Alexander Korznikov |
|
# Thanks to Alexander Korznikov |
|
||||||
# http://www.korznikov.com/2014/12/bash-tab-completion-for-awesome-tool.html |
|
# http://www.korznikov.com/2014/12/bash-tab-completion-for-awesome-tool.html |
|
||||||
# |
|
# |
|
||||||
# ---------------------------------------------------------------------------+
|
# ---------------------------------------------------------------------------+
|
||||||
|
|
||||||
if command -v sqlmap > /dev/null; then
|
if _command_exists sqlmap
|
||||||
|
then
|
||||||
|
|
||||||
_sqlmap()
|
function _sqlmap()
|
||||||
{
|
{
|
||||||
local cur prev
|
local cur prev
|
||||||
|
|
||||||
COMPREPLY=()
|
COMPREPLY=()
|
||||||
cur=$(_get_cword)
|
cur="$(_get_cword)"
|
||||||
prev=$(_get_pword)
|
prev="$(_get_pword)"
|
||||||
|
|
||||||
case $prev in
|
case $prev in
|
||||||
|
|
||||||
|
|
@ -143,7 +144,7 @@ if command -v sqlmap > /dev/null; then
|
||||||
--mobile --page-rank --purge-output --smart \
|
--mobile --page-rank --purge-output --smart \
|
||||||
--sqlmap-shell --wizard '
|
--sqlmap-shell --wizard '
|
||||||
COMPREPLY=( $( \
|
COMPREPLY=( $( \
|
||||||
(while read -d ' ' i; do
|
(while read -d ' ' i; do
|
||||||
[[ -z "$i" || "${onlyonce/ ${i%% *} / }" == "$onlyonce" ]] &&
|
[[ -z "$i" || "${onlyonce/ ${i%% *} / }" == "$onlyonce" ]] &&
|
||||||
continue
|
continue
|
||||||
# flatten array with spaces on either side,
|
# flatten array with spaces on either side,
|
||||||
|
|
@ -152,7 +153,7 @@ if command -v sqlmap > /dev/null; then
|
||||||
COMPREPLY=" ${COMPREPLY[@]} "
|
COMPREPLY=" ${COMPREPLY[@]} "
|
||||||
# remove word from list of completions
|
# remove word from list of completions
|
||||||
COMPREPLY=( ${COMPREPLY/ ${i%% *} / } )
|
COMPREPLY=( ${COMPREPLY/ ${i%% *} / } )
|
||||||
done
|
done
|
||||||
printf '%s ' "${COMPREPLY[@]}") <<<"${COMP_WORDS[@]}"
|
printf '%s ' "${COMPREPLY[@]}") <<<"${COMP_WORDS[@]}"
|
||||||
) )
|
) )
|
||||||
|
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,25 +1,52 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
|
#
|
||||||
# Loads the system's Bash completion modules.
|
# Loads the system's Bash completion modules.
|
||||||
# If Homebrew is installed (OS X), it's Bash completion modules are loaded.
|
# If Homebrew is installed (OS X), it's Bash completion modules are loaded.
|
||||||
|
|
||||||
if [[ -r /etc/bash_completion ]] ; then
|
# Load before other completions
|
||||||
# shellcheck disable=SC1091
|
# BASH_IT_LOAD_PRIORITY: 325
|
||||||
source /etc/bash_completion
|
|
||||||
|
|
||||||
|
# Bash-completion is too large and complex to expect to handle unbound variables throughout the whole codebase.
|
||||||
|
if shopt -qo nounset; then
|
||||||
|
__bash_it_restore_nounset=true
|
||||||
|
shopt -uo nounset
|
||||||
|
else
|
||||||
|
__bash_it_restore_nounset=false
|
||||||
|
fi
|
||||||
|
|
||||||
|
# shellcheck disable=SC1090 disable=SC1091
|
||||||
|
if [[ -r "${BASH_COMPLETION:-}" ]]; then
|
||||||
|
source "${BASH_COMPLETION}"
|
||||||
|
elif [[ -r /etc/bash_completion ]]; then
|
||||||
|
source /etc/bash_completion
|
||||||
# Some distribution makes use of a profile.d script to import completion.
|
# Some distribution makes use of a profile.d script to import completion.
|
||||||
elif [[ -r /etc/profile.d/bash_completion.sh ]] ; then
|
elif [[ -r /etc/profile.d/bash_completion.sh ]]; then
|
||||||
# shellcheck disable=SC1091
|
source /etc/profile.d/bash_completion.sh
|
||||||
source /etc/profile.d/bash_completion.sh
|
elif _bash_it_homebrew_check; then
|
||||||
|
: "${BASH_COMPLETION_COMPAT_DIR:=${BASH_IT_HOMEBREW_PREFIX}/etc/bash_completion.d}"
|
||||||
|
case "${BASH_VERSION}" in
|
||||||
|
1* | 2* | 3.0* | 3.1*)
|
||||||
|
_log_warning "Cannot load completion due to version of shell. Are you using Bash 3.2+?"
|
||||||
|
;;
|
||||||
|
3.2* | 4.0* | 4.1*)
|
||||||
|
# Import version 1.x of bash-completion, if installed.
|
||||||
|
BASH_COMPLETION="${BASH_IT_HOMEBREW_PREFIX}/opt/bash-completion@1/etc/bash_completion"
|
||||||
|
if [[ -r "$BASH_COMPLETION" ]]; then
|
||||||
|
source "$BASH_COMPLETION"
|
||||||
|
else
|
||||||
|
unset BASH_COMPLETION
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
4.2* | 5* | *)
|
||||||
|
# homebrew/versions/bash-completion2 (required for projects.completion.bash) is installed to this path
|
||||||
|
if [[ -r "${BASH_IT_HOMEBREW_PREFIX}/opt/bash-completion@2/etc/profile.d/bash_completion.sh" ]]; then
|
||||||
|
source "${BASH_IT_HOMEBREW_PREFIX}/opt/bash-completion@2/etc/profile.d/bash_completion.sh"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ "$(uname -s)" == 'Darwin' ]] && _command_exists brew ; then
|
if [[ ${__bash_it_restore_nounset:-false} == "true" ]]; then
|
||||||
BREW_PREFIX=${BREW_PREFIX:-$(brew --prefix)}
|
shopt -so nounset
|
||||||
|
|
||||||
# homebrew/versions/bash-completion2 (required for projects.completion.bash) is installed to this path
|
|
||||||
if [[ -r "$BREW_PREFIX"/etc/profile.d/bash_completion.sh ]] ; then
|
|
||||||
# shellcheck disable=SC1090
|
|
||||||
source "$BREW_PREFIX"/etc/profile.d/bash_completion.sh
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
unset __bash_it_restore_nounset
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,10 @@
|
||||||
if [[ -x "$(which travis)" ]]; then
|
# shellcheck shell=bash
|
||||||
__TRAVIS_COMPLETION_SCRIPT="${TRAVIS_CONFIG_PATH:-${HOME}/.travis}/travis.sh"
|
|
||||||
[[ -f "${__TRAVIS_COMPLETION_SCRIPT}" ]] && source "${__TRAVIS_COMPLETION_SCRIPT}"
|
if _command_exists travis
|
||||||
|
then
|
||||||
|
if [[ -s "${__TRAVIS_COMPLETION_SCRIPT:=${TRAVIS_CONFIG_PATH:-${HOME}/.travis}/travis.sh}" ]]
|
||||||
|
then
|
||||||
|
source "${__TRAVIS_COMPLETION_SCRIPT}"
|
||||||
|
fi
|
||||||
unset __TRAVIS_COMPLETION_SCRIPT
|
unset __TRAVIS_COMPLETION_SCRIPT
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,9 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
__vuejs_completion() {
|
__vuejs_completion() {
|
||||||
|
# shellcheck disable=SC2155
|
||||||
local prev=$(_get_pword)
|
local prev=$(_get_pword)
|
||||||
|
# shellcheck disable=SC2155
|
||||||
local curr=$(_get_cword)
|
local curr=$(_get_cword)
|
||||||
|
|
||||||
case $prev in
|
case $prev in
|
||||||
|
|
|
||||||
|
|
@ -1,15 +1,16 @@
|
||||||
#!/usr/bin/bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
if command -v wpscan > /dev/null; then
|
_command_exists wpscan || return
|
||||||
__wpscan_completion() {
|
|
||||||
local OPTS=("--help --hh --version --url --ignore-main-redirect --verbose --output --format --detection-mode --scope --headers --user-agent --vhost --random-user-agent --user-agents-list --http-auth --max-threads --throttle --request-timeout --connect-timeout --disable-tlc-checks --proxy --proxy-auth --cookie-string --cookie-jar --cache-ttl --clear-cache --server --cache-dir --update --no-update --wp-content-dir --wp-plugins-dir --wp-version-detection --main-theme-detection --enumerate --exclude-content-based --plugins-list --plugins-detection --plugins-version-all --plugins-version-detection --themes-list --themes-detection --themes-version-all --themes-version-detection --timthumbs-list --timthumbs-detection --config-backups-list --config-backups-detection --db-exports-list --db-exports-detection --medias-detection --users-list --users-detection --passwords --usernames --multicall-max-passwords --password-attack --stealthy")
|
|
||||||
COMPREPLY=()
|
|
||||||
for _opt_ in ${OPTS[@]}; do
|
|
||||||
if [[ "$_opt_" == "$2"* ]]; then
|
|
||||||
COMPREPLY+=("$_opt_")
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
complete -F __wpscan_completion wpscan
|
function __wpscan_completion() {
|
||||||
fi
|
local _opt_
|
||||||
|
local OPTS=('--help' '--hh' '--version' '--url' '--ignore-main-redirect' '--verbose' '--output' '--format' '--detection-mode' '--scope' '--headers' '--user-agent' '--vhost' '--random-user-agent' '--user-agents-list' '--http-auth' '--max-threads' '--throttle' '--request-timeout' '--connect-timeout' '--disable-tlc-checks' '--proxy' '--proxy-auth' '--cookie-string' '--cookie-jar' '--cache-ttl' '--clear-cache' '--server' '--cache-dir' '--update' '--no-update' '--wp-content-dir' '--wp-plugins-dir' '--wp-version-detection' '--main-theme-detection' '--enumerate' '--exclude-content-based' '--plugins-list' '--plugins-detection' '--plugins-version-all' '--plugins-version-detection' '--themes-list' '--themes-detection' '--themes-version-all' '--themes-version-detection' '--timthumbs-list' '--timthumbs-detection' '--config-backups-list' '--config-backups-detection' '--db-exports-list' '--db-exports-detection' '--medias-detection' '--users-list' '--users-detection' '--passwords' '--usernames' '--multicall-max-passwords' '--password-attack' '--stealthy')
|
||||||
|
COMPREPLY=()
|
||||||
|
for _opt_ in "${OPTS[@]}"; do
|
||||||
|
if [[ "$_opt_" == "$2"* ]]; then
|
||||||
|
COMPREPLY+=("$_opt_")
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
complete -F __wpscan_completion wpscan
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
about-completion "yarn cli completions"
|
||||||
|
|
||||||
|
# shellcheck disable=SC1090 source=../../vendor/github.com/dsifford/yarn-completion/yarn
|
||||||
|
source "${BASH_IT}/vendor/github.com/dsifford/yarn-completion/yarn"
|
||||||
|
|
@ -1,7 +1,9 @@
|
||||||
# Bash-it
|

|
||||||

|
|
||||||
|

|
||||||

|

|
||||||
[](https://webchat.freenode.net/?channel=#bash-it)
|

|
||||||
|

|
||||||
|
|
||||||
**Bash-it** is a collection of community Bash commands and scripts for Bash 3.2+.
|
**Bash-it** is a collection of community Bash commands and scripts for Bash 3.2+.
|
||||||
(And a shameless ripoff of [oh-my-zsh](https://github.com/robbyrussell/oh-my-zsh) :smiley:)
|
(And a shameless ripoff of [oh-my-zsh](https://github.com/robbyrussell/oh-my-zsh) :smiley:)
|
||||||
|
|
@ -39,7 +41,8 @@ Stop polluting your `~/bin` directory and your `.bashrc` file, fork/clone Bash-i
|
||||||
``git clone --depth=1 https://github.com/Bash-it/bash-it.git ~/.bash_it``
|
``git clone --depth=1 https://github.com/Bash-it/bash-it.git ~/.bash_it``
|
||||||
2) Run ``~/.bash_it/install.sh``
|
2) Run ``~/.bash_it/install.sh``
|
||||||
|
|
||||||
Thats it! :smiley:
|
That's it! :smiley:
|
||||||
|
|
||||||
You can check out more components of Bash-it, and customize it to your desire.
|
You can check out more components of Bash-it, and customize it to your desire.
|
||||||
For more information, see detailed instructions [here](https://bash-it.readthedocs.io/en/latest/installation/).
|
For more information, see detailed instructions [here](https://bash-it.readthedocs.io/en/latest/installation/).
|
||||||
|
|
||||||
|
|
@ -53,6 +56,8 @@ please feel free to read through this page if you're interested in how Bash-it l
|
||||||
|
|
||||||
## Contributors
|
## Contributors
|
||||||
|
|
||||||
* [List of contributors][contribute]
|
[List of contributors](https://github.com/Bash-it/bash-it/contributors)
|
||||||
|
|
||||||
[contribute]: https://github.com/Bash-it/bash-it/contributors
|
## License
|
||||||
|
|
||||||
|
Bash-it is licensed under the [MIT License](https://github.com/Bash-it/bash-it/blob/master/LICENSE).
|
||||||
|
|
|
||||||
|
|
@ -13,3 +13,4 @@ You should be familiar with them in order to fully utilize Bash-it.
|
||||||
search
|
search
|
||||||
reload
|
reload
|
||||||
doctor
|
doctor
|
||||||
|
profile
|
||||||
|
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue