Compare commits
1013 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 | |
|
|
4607ee7452 | |
|
|
0eab2962d3 | |
|
|
0e77a94140 | |
|
|
a0ba2a1787 | |
|
|
0dd01da4b7 | |
|
|
7fb7e27921 | |
|
|
751d3e2496 | |
|
|
e8342c1d97 | |
|
|
2d56cc4167 | |
|
|
25c1c8978e | |
|
|
133e48229a | |
|
|
e25e371ba7 | |
|
|
e4e0c151b2 | |
|
|
db318cdd3e | |
|
|
6870abc4fc | |
|
|
e4f6006797 | |
|
|
5c192575ce | |
|
|
3e7adde638 | |
|
|
fe9ef1e4bd | |
|
|
75058ebf22 | |
|
|
5cb52fa239 | |
|
|
77654875e5 | |
|
|
63f9f660a9 | |
|
|
92d814b2f6 | |
|
|
0d963b224f | |
|
|
e9f28ff745 | |
|
|
dbfcb431a8 | |
|
|
1d2a2fcd9a | |
|
|
af17501318 | |
|
|
9e37f0d09e | |
|
|
ef10bcd151 | |
|
|
1fbd91ebf9 | |
|
|
71116f785f | |
|
|
84049a4542 | |
|
|
aebe193136 | |
|
|
e690f21e4e | |
|
|
ff2f961ad7 | |
|
|
ce6487f63e | |
|
|
49d7d2e8c4 | |
|
|
8fcf713541 | |
|
|
90dd69c8ad | |
|
|
a0b6c4993a | |
|
|
293d86771a | |
|
|
e8dc0f7434 | |
|
|
2500fe7dda | |
|
|
1ce93fd60e | |
|
|
b6d95c71ce | |
|
|
69e5a28ed3 | |
|
|
28b2a2ba2b | |
|
|
3d3322d0c9 | |
|
|
6fb9379f92 | |
|
|
645054a8c4 | |
|
|
868d64ebb8 | |
|
|
202531321d | |
|
|
253e87e4a2 | |
|
|
d4bf4e6a89 | |
|
|
0748b3085e | |
|
|
714bf84528 | |
|
|
391ce6e91f | |
|
|
42695c22d0 | |
|
|
a8695edc8f | |
|
|
71c0c06a78 | |
|
|
5df1e653d9 | |
|
|
7959acddd9 | |
|
|
c2d971f20e | |
|
|
adc77bb622 | |
|
|
2b66100c47 | |
|
|
759cdd5a6d | |
|
|
8969f018a4 | |
|
|
9915f85e8b | |
|
|
94a9c639c7 | |
|
|
067149725d | |
|
|
ba5700e555 | |
|
|
8dfc4cee20 | |
|
|
2e3cf0b3c0 | |
|
|
5b51842b54 | |
|
|
846a576978 | |
|
|
284819e718 | |
|
|
f9bc244718 | |
|
|
2c429e5bb1 | |
|
|
b93ac7785c | |
|
|
ef110e167c | |
|
|
37a7fac128 | |
|
|
1d569573da | |
|
|
0d0fde9904 | |
|
|
25b3c96f43 | |
|
|
cb5047734b | |
|
|
3a846a2d47 | |
|
|
2388c74d84 | |
|
|
c79d6cd609 | |
|
|
9b04e11bfc | |
|
|
4f8fd5957f | |
|
|
7b817f388d | |
|
|
2db806fe0d | |
|
|
e80e29be6d | |
|
|
70f0111f69 | |
|
|
812efaab90 | |
|
|
49cf84c4fe | |
|
|
6b3788051f | |
|
|
046e528cc2 | |
|
|
29855ed1e6 | |
|
|
e2be8bc2bc | |
|
|
5ad497924c | |
|
|
c9a7837b44 | |
|
|
54bf7f9a59 | |
|
|
bb6354e205 | |
|
|
2a2741d761 | |
|
|
c7f6e80ad0 | |
|
|
f86d823dc3 | |
|
|
d2ab59fef8 | |
|
|
b92f53ece5 | |
|
|
ef42c822e6 | |
|
|
79df5ffc3c | |
|
|
18781ed397 | |
|
|
988e966df3 | |
|
|
814ff562e9 | |
|
|
86fd073ee6 | |
|
|
662a5c4ac7 | |
|
|
eadd2685df | |
|
|
8691894175 | |
|
|
cfb9a22e70 | |
|
|
fb0fa7f799 | |
|
|
59fc8c818d | |
|
|
4044f4123c | |
|
|
61f727fb96 | |
|
|
5e667ed476 | |
|
|
bd6dbd3edf | |
|
|
bb35450c17 | |
|
|
610980dd23 | |
|
|
a9b0ec7d1d | |
|
|
957cd578f7 | |
|
|
a0ea33d671 | |
|
|
bc32b40088 | |
|
|
70fa3f8d25 | |
|
|
bac50413f1 | |
|
|
da662d1332 | |
|
|
9f66059f52 | |
|
|
dd4e410a32 | |
|
|
8723fc56b2 | |
|
|
436381de93 | |
|
|
94d261b42d | |
|
|
5a761b7ae3 | |
|
|
3f29862478 | |
|
|
08ff08e043 | |
|
|
e574abbbba | |
|
|
6495e3479e | |
|
|
df73085fea | |
|
|
6065d003e8 | |
|
|
c268cd9abc | |
|
|
342ddcfca0 | |
|
|
73d28f0b27 | |
|
|
f18562279c | |
|
|
2ae03668c4 | |
|
|
91f63c0b68 | |
|
|
e932d8371f | |
|
|
3fce1ffe8d | |
|
|
fe7d3ef177 | |
|
|
56348b1a12 | |
|
|
cc3bdc2b57 | |
|
|
d97a36af88 | |
|
|
c5f02b769d | |
|
|
81e3f1482b | |
|
|
c168122ff5 | |
|
|
f255d03057 | |
|
|
60da498ed4 | |
|
|
ae9da3b62b | |
|
|
3c00fe6dbb | |
|
|
5ca2c43aed | |
|
|
0b6ecf705d | |
|
|
3addebb66b | |
|
|
ded58f25e3 | |
|
|
b8dda491c7 | |
|
|
13020874a9 | |
|
|
5487963fa7 | |
|
|
0565c3aa8e | |
|
|
3c0235b44b | |
|
|
aeb0cb7353 | |
|
|
49886620c4 | |
|
|
8e73b538ea | |
|
|
012552d8b7 | |
|
|
a369cc7c0a | |
|
|
cd44880c15 | |
|
|
292da7ef77 | |
|
|
59439c2f62 | |
|
|
8cc7327c0b | |
|
|
5188b3b0c0 | |
|
|
334005ead3 | |
|
|
6eb5802080 | |
|
|
3ba1a14eb9 | |
|
|
f4f229573d | |
|
|
6a69931240 | |
|
|
f221cdca9e | |
|
|
17211b0b1a | |
|
|
2329b4395b | |
|
|
3a2ccd3792 | |
|
|
1d4b325ce9 | |
|
|
a1da0087a1 | |
|
|
d6e2b04708 | |
|
|
908fed9f50 | |
|
|
13e795c995 | |
|
|
e94b9420ac | |
|
|
b119540ce7 | |
|
|
d2a5524556 | |
|
|
921ea9ac76 | |
|
|
b19c2b969f | |
|
|
d74cc615be | |
|
|
5aa2612ff1 | |
|
|
6914a2345a | |
|
|
8bc83b2d48 | |
|
|
9ca6841e20 | |
|
|
e1372dd5bd | |
|
|
7edc26f408 | |
|
|
d00c478ded | |
|
|
13be44ab19 | |
|
|
181863af1d | |
|
|
859038e58f | |
|
|
501b1ab3b5 | |
|
|
89787cf261 | |
|
|
2b4a81f39c | |
|
|
5eb023cf51 | |
|
|
6008006783 | |
|
|
f10834275f | |
|
|
1c05d71819 | |
|
|
f5753e4416 | |
|
|
654a49cbd8 | |
|
|
b5fecb3eb3 | |
|
|
0d7f145ef4 | |
|
|
dca563e606 | |
|
|
cf2df9e896 | |
|
|
28e4633e53 | |
|
|
1ab755360d | |
|
|
e7d5107007 | |
|
|
60c8b4be9f | |
|
|
d3d9a79f1e | |
|
|
bced06994b | |
|
|
d89651dc8d | |
|
|
7b21a76c6a | |
|
|
4dfd8bcc42 | |
|
|
a1760af43b | |
|
|
3019dc331d | |
|
|
9b837b4f59 | |
|
|
b4e515f19b | |
|
|
0e6f10f489 | |
|
|
5a85126241 | |
|
|
6bcabb1503 | |
|
|
9904857132 | |
|
|
18365035a9 | |
|
|
b444ac4e54 | |
|
|
0e904abd0d | |
|
|
e873252227 | |
|
|
7dcf4dd186 | |
|
|
7f1aa107d8 | |
|
|
d448ea8cf1 | |
|
|
d5c2fdc672 | |
|
|
4d51bfcaf4 | |
|
|
4a5ea95e2e | |
|
|
8198fafbd9 | |
|
|
1702e0217a | |
|
|
d9364ced7a | |
|
|
929321ad0a | |
|
|
c13850faa2 | |
|
|
8ce9d8daa5 | |
|
|
13deafbb1b | |
|
|
794f0e321e | |
|
|
63ad4897ef | |
|
|
b70da511f2 | |
|
|
06b1ffecc0 | |
|
|
bd8b8bb21e | |
|
|
d84d6a8356 | |
|
|
f5fe3dbeb0 | |
|
|
689758cf71 | |
|
|
889259dfec | |
|
|
72f5c2ada0 | |
|
|
864970bcd2 | |
|
|
5cdb98f802 | |
|
|
621ac92ae1 | |
|
|
bcc3f4080b | |
|
|
48333b9816 | |
|
|
75bd5c85c1 | |
|
|
ff208775a5 | |
|
|
a858e75456 | |
|
|
52c0f6564e | |
|
|
da9b710014 | |
|
|
447448b357 | |
|
|
9edba505b5 | |
|
|
d5e54596a9 | |
|
|
600b425e0a | |
|
|
a717283163 | |
|
|
0076db0efb | |
|
|
3844b652b4 | |
|
|
1228418653 | |
|
|
f7e295f691 | |
|
|
6abb26c6c6 | |
|
|
b667a71995 | |
|
|
3f68817047 | |
|
|
af6af2d932 | |
|
|
0b9da701c4 | |
|
|
dd1474990c | |
|
|
54116fc068 | |
|
|
1f5d9b757f | |
|
|
507e4bec82 | |
|
|
eca68db8cc | |
|
|
81f7af5036 | |
|
|
3a1283dad5 | |
|
|
c42e3e8b21 | |
|
|
3f318914fd | |
|
|
d150fc6ec1 | |
|
|
2acf26b7b3 | |
|
|
45d076567a | |
|
|
b14a38fec9 | |
|
|
5045867b2c | |
|
|
d986261f98 | |
|
|
250bd2bbd8 | |
|
|
9ac6a6ab96 | |
|
|
e290af4eec | |
|
|
93cc173815 | |
|
|
313abebbb0 | |
|
|
e023d6f851 | |
|
|
449d6d4fe1 |
|
|
@ -5,11 +5,32 @@ indent_style = space
|
||||||
indent_size = 2
|
indent_size = 2
|
||||||
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
|
||||||
|
|
||||||
[*.md]
|
[**.{md,rst}]
|
||||||
trim_trailing_whitespace = false
|
trim_trailing_whitespace = false
|
||||||
|
|
||||||
[.git*]
|
[.git*]
|
||||||
|
indent_size = tab
|
||||||
indent_style = tab
|
indent_style = tab
|
||||||
|
|
||||||
|
[{**.*sh,test/run,**.bats}]
|
||||||
|
indent_size = tab
|
||||||
|
indent_style = tab
|
||||||
|
|
||||||
|
shell_variant = bash
|
||||||
|
binary_next_line = true # like -bn
|
||||||
|
switch_case_indent = true # like -ci
|
||||||
|
space_redirects = true # like -sr
|
||||||
|
keep_padding = false # like -kp
|
||||||
|
end_of_line = lf
|
||||||
|
charset = utf-8
|
||||||
|
trim_trailing_whitespace = true
|
||||||
|
insert_final_newline = true
|
||||||
|
|
||||||
|
[**.bats]
|
||||||
|
indent_size = tab
|
||||||
|
indent_style = tab
|
||||||
|
shell_variant = bats
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1,9 @@
|
||||||
*.sh text eol=lf
|
*.sh text eol=lf
|
||||||
*.bash text eol=lf
|
*.bash text eol=lf
|
||||||
|
|
||||||
|
# Docs allow trailing whitespaces
|
||||||
|
*.md whitespace=-blank-at-eol
|
||||||
|
*.rst whitespace=-blank-at-eol
|
||||||
|
|
||||||
|
# Windows files
|
||||||
|
*.bat text eol=crlf
|
||||||
|
|
|
||||||
|
|
@ -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
|
||||||
|
|
@ -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.
|
||||||
|
|
@ -0,0 +1,30 @@
|
||||||
|
<!--- Provide a general summary of your changes in the Title above -->
|
||||||
|
|
||||||
|
## Description
|
||||||
|
<!--- Describe your changes in detail -->
|
||||||
|
|
||||||
|
## Motivation and Context
|
||||||
|
<!--- Why is this change required? What problem does it solve? -->
|
||||||
|
<!--- If it fixes an open issue, please link to the issue here. -->
|
||||||
|
|
||||||
|
## How Has This Been Tested?
|
||||||
|
<!--- Please describe in detail how you tested your changes. -->
|
||||||
|
<!--- Include details of your testing environment, and the tests you ran to -->
|
||||||
|
<!--- see how your change affects other areas of the code, etc. -->
|
||||||
|
|
||||||
|
## Screenshots (if appropriate):
|
||||||
|
|
||||||
|
## Types of changes
|
||||||
|
<!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply: -->
|
||||||
|
- [ ] Bug fix (non-breaking change which fixes an issue)
|
||||||
|
- [ ] New feature (non-breaking change which adds functionality)
|
||||||
|
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
|
||||||
|
|
||||||
|
## Checklist:
|
||||||
|
<!--- Go over all the following points, and put an `x` in all the boxes that apply. -->
|
||||||
|
<!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->
|
||||||
|
- [ ] My code follows the code style of this project.
|
||||||
|
- [ ] If my change requires a change to the documentation, I have updated the documentation accordingly.
|
||||||
|
- [ ] I have read the **CONTRIBUTING** document.
|
||||||
|
- [ ] If I have added a new file, I also added it to ``clean_files.txt`` and formatted it using ``lint_clean_files.sh``.
|
||||||
|
- [ ] I have added tests to cover my changes, and all the new and existing tests pass.
|
||||||
|
|
@ -0,0 +1,11 @@
|
||||||
|
# Configuration for probot-no-response - https://github.com/probot/no-response
|
||||||
|
|
||||||
|
# Number of days of inactivity before an Issue is closed for lack of response
|
||||||
|
daysUntilClose: 14
|
||||||
|
# Label requiring a response
|
||||||
|
responseRequiredLabel: waiting-for-response
|
||||||
|
# Comment to post when closing an Issue for lack of response. Set to `false` to disable
|
||||||
|
closeComment: >
|
||||||
|
This issue has been automatically closed because there has been no response
|
||||||
|
to our request for more information from the original author.
|
||||||
|
You can always reopen the issue if needed.
|
||||||
|
|
@ -0,0 +1,66 @@
|
||||||
|
name: CI
|
||||||
|
|
||||||
|
# Triggers the workflow on push or pull request events
|
||||||
|
on: [push, pull_request]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
bats-test:
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [ubuntu-20.04, ubuntu-22.04, macos-12, macos-11]
|
||||||
|
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Install greadlink
|
||||||
|
if: startsWith(runner.os, 'macOS')
|
||||||
|
run: brew install coreutils
|
||||||
|
- name: Install parallel
|
||||||
|
if: startsWith(runner.os, 'macOS')
|
||||||
|
run: brew install parallel
|
||||||
|
- name: Test code
|
||||||
|
run: test/run
|
||||||
|
|
||||||
|
build-docs:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v2
|
||||||
|
with:
|
||||||
|
python-version: 3.8
|
||||||
|
- name: Install docs dependencies
|
||||||
|
run: python3 -m pip install -r docs/requirements.txt
|
||||||
|
- name: Build the docs
|
||||||
|
run: sphinx-build -W -b html docs docs/_build/html
|
||||||
|
|
||||||
|
lint:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Set up Go
|
||||||
|
uses: actions/setup-go@v2
|
||||||
|
with:
|
||||||
|
go-version: 1.17
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v2
|
||||||
|
with:
|
||||||
|
python-version: 3.8
|
||||||
|
# - name: Update APT Package Lists
|
||||||
|
# run: sudo apt-get update
|
||||||
|
- name: Install shfmt
|
||||||
|
run: GO111MODULE=on go get mvdan.cc/sh/v3/cmd/shfmt
|
||||||
|
- name: 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
|
||||||
|
run: python3 -m pip install -r test/lint-requirements.txt
|
||||||
|
- name: Run lint
|
||||||
|
run: ./lint_clean_files.sh
|
||||||
|
|
@ -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
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,50 @@
|
||||||
|
# See https://pre-commit.com for more information
|
||||||
|
# See https://pre-commit.com/hooks.html for more hooks
|
||||||
|
---
|
||||||
|
# fail_fast: true
|
||||||
|
minimum_pre_commit_version: 1.18.1
|
||||||
|
exclude: "docs/_build/"
|
||||||
|
repos:
|
||||||
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||||
|
rev: v2.3.0
|
||||||
|
hooks:
|
||||||
|
- id: trailing-whitespace
|
||||||
|
exclude: ".(md|rst)$"
|
||||||
|
- id: end-of-file-fixer
|
||||||
|
- id: check-merge-conflict
|
||||||
|
- id: mixed-line-ending
|
||||||
|
- id: check-added-large-files
|
||||||
|
- repo: https://github.com/jumanjihouse/pre-commit-hooks
|
||||||
|
rev: 2.1.5
|
||||||
|
hooks:
|
||||||
|
- id: git-check # Configure in .gitattributes
|
||||||
|
- id: shellcheck
|
||||||
|
exclude: ".bats$"
|
||||||
|
- id: shfmt
|
||||||
|
exclude: ".bats$"
|
||||||
|
- repo: https://github.com/Lucas-C/pre-commit-hooks
|
||||||
|
rev: v1.1.7
|
||||||
|
hooks:
|
||||||
|
# - id: forbid-crlf
|
||||||
|
- id: remove-crlf
|
||||||
|
exclude: ".bat$"
|
||||||
|
- repo: local
|
||||||
|
hooks:
|
||||||
|
- id: dot-sh
|
||||||
|
name: Check .sh files against bash-it requirements
|
||||||
|
entry: ./hooks/dot-sh.sh
|
||||||
|
language: system
|
||||||
|
files: "\\.sh$"
|
||||||
|
types: [file]
|
||||||
|
- id: dot-bash
|
||||||
|
name: Check .bash files against bash-it requirements
|
||||||
|
exclude: "test/test_helper.bash"
|
||||||
|
entry: ./hooks/dot-bash.sh
|
||||||
|
language: system
|
||||||
|
files: "\\.bash$"
|
||||||
|
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
|
||||||
|
|
@ -0,0 +1,10 @@
|
||||||
|
version: 2
|
||||||
|
|
||||||
|
sphinx:
|
||||||
|
builder: htmldir
|
||||||
|
configuration: docs/conf.py
|
||||||
|
|
||||||
|
python:
|
||||||
|
version: 3.7
|
||||||
|
install:
|
||||||
|
- requirements: docs/requirements.txt
|
||||||
31
.travis.yml
31
.travis.yml
|
|
@ -1,31 +0,0 @@
|
||||||
# YAML anchors need to appear first.
|
|
||||||
# Keys starting with an underscore are the custom ones, refer to
|
|
||||||
# https://docs.travis-ci.com/user/build-config-yaml#private-keys-as-yaml-anchors-and-aliases-and-external-tooling
|
|
||||||
|
|
||||||
_native_job: &native_job
|
|
||||||
script: |
|
|
||||||
test/run
|
|
||||||
|
|
||||||
language: shell
|
|
||||||
|
|
||||||
os: linux
|
|
||||||
|
|
||||||
dist: xenial
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
- <<: *native_job
|
|
||||||
name: Ubuntu 16.04
|
|
||||||
|
|
||||||
- <<: *native_job
|
|
||||||
name: Ubuntu 18.04
|
|
||||||
dist: bionic
|
|
||||||
|
|
||||||
- <<: *native_job
|
|
||||||
name: MacOS xcode9.4
|
|
||||||
os: osx
|
|
||||||
osx_image: xcode9.4 # Default xcode on Travis.
|
|
||||||
|
|
||||||
- <<: *native_job
|
|
||||||
name: MacOS xcode11.5
|
|
||||||
os: osx
|
|
||||||
osx_image: xcode11.5 # Latest xcode on Travis.
|
|
||||||
|
|
@ -1,91 +0,0 @@
|
||||||
# Contribution Guidelines
|
|
||||||
|
|
||||||
When contributing a new feature, a bug fix, a new theme, or any other change to Bash-it, please consider the following guidelines.
|
|
||||||
Most of this is common sense, but please try to stick to the conventions listed here.
|
|
||||||
|
|
||||||
## Issues
|
|
||||||
|
|
||||||
* When opening a new issue in the issue tracker, please include information about which _Operating System_ you're using, and which version of _Bash_.
|
|
||||||
* In many cases, it also makes sense to show which Bash-it plugins you are using.
|
|
||||||
This information can be obtained using `bash-it show plugins`.
|
|
||||||
* If the issue happens while loading Bash-it, please also include your `~/.bash_profile` or `~/.bashrc` file,
|
|
||||||
as well as the install location of Bash-it (default should be `~/.bash_it`).
|
|
||||||
* When reporting a bug or requesting a new feature, consider providing a Pull Request that fixes the issue or can be used as a starting point for the new feature.
|
|
||||||
Don't be afraid, most things aren't that complex...
|
|
||||||
|
|
||||||
## Pull Requests
|
|
||||||
|
|
||||||
* Fork the Bash-it repo, create a new feature branch from _master_ and apply your changes there.
|
|
||||||
Create a _Pull Request_ from your feature branch against Bash-it's _master_ branch.
|
|
||||||
* Limit each Pull Request to one feature.
|
|
||||||
Don't bundle multiple features/changes (e.g. a new _Theme_ and a fix to an existing plugin) into a single Pull Request - create one PR for the theme, and a separate PR for the fix.
|
|
||||||
* For complex changes, try to _squash_ your changes into a single commit before
|
|
||||||
pushing code. Once you've pushed your code and opened a PR, please refrain
|
|
||||||
from force-pushing changes to the PR branch – remember, Bash-it is a
|
|
||||||
distributed project and your branch may be in use already.
|
|
||||||
* When in doubt, open a PR with too many commits. Bash-it is a learning project
|
|
||||||
for everyone involved. Showing your work provides a great history for folks
|
|
||||||
to learn what works and what didn't.
|
|
||||||
|
|
||||||
## Code Style
|
|
||||||
|
|
||||||
* Try to stick to the existing code style. Please don't reformat or change the syntax of existing code simply because you don't like that style.
|
|
||||||
* Indentation is using spaces, not tabs. Most of the code is indented with 2 spaces, some with 4 spaces. Please try to stick to 2 spaces.
|
|
||||||
If you're using an editor that supports [EditorConfig](http://EditorConfig.org), the editor should automatically use the settings defined in Bash-it's [.editorconfig file](.editorconfig).
|
|
||||||
* When creating new functions, please use a dash ("-") to separate the words of the function's name, e.g. `my-new-function`.
|
|
||||||
Don't use underscores, e.g. `my_new_function`.
|
|
||||||
* Internal functions that aren't to be used by the end user should start with an underscore, e.g. `_my-new-internal-function`.
|
|
||||||
* Use the provided meta functions to document your code, e.g. `about-plugin`, `about`, `group`, `param`, `example`.
|
|
||||||
This will make it easier for other people to use your new functionality.
|
|
||||||
Take a look at the existing code for an example (e.g. [the base plugin](plugins/available/base.plugin.bash)).
|
|
||||||
* When adding files, please use the existing file naming conventions, e.g. plugin files need to end in `.plugin.bash`.
|
|
||||||
This is important for the installation functionality.
|
|
||||||
* When using the `$BASH_IT` variable, please always enclose it in double quotes to ensure that the code also works when Bash-it is installed in a directory that contains spaces in its name: `for f in "${BASH_IT}/plugins/available"/*.bash ; do echo "$f" ; done`
|
|
||||||
* Bash-it supports Bash 3.2 and higher. Please don't use features only available in Bash 4, such as associative arrays.
|
|
||||||
|
|
||||||
## Unit Tests
|
|
||||||
|
|
||||||
When adding features or making changes/fixes, please run our growing unit test suite to ensure that you did not break existing functionality.
|
|
||||||
The test suite does not cover all aspects of Bash-it, but please run it anyway to verify that you did not introduce any regression issues.
|
|
||||||
|
|
||||||
Any code pushed to GitHub as part of a Pull Request will automatically trigger a continuous integration build on [Travis CI](https://travis-ci.org/Bash-it/bash-it), where the test suite is run on both Linux and macOS.
|
|
||||||
The Pull Request will then show the result of the Travis build, indicating whether all tests ran fine, or whether there were issues.
|
|
||||||
Please pay attention to this, Pull Requests with build issues will not be merged.
|
|
||||||
|
|
||||||
Adding new functionality or changing existing functionality is a good opportunity to increase Bash-it's test coverage.
|
|
||||||
When you're changing the Bash-it codebase, please consider adding some unit tests that cover the new or changed functionality.
|
|
||||||
Ideally, when fixing a bug, a matching unit test that verifies that the bug is no longer present, is added at the same time.
|
|
||||||
|
|
||||||
To run the test suite, simply execute the following in the directory where you cloned Bash-it:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
test/run
|
|
||||||
```
|
|
||||||
|
|
||||||
This command will ensure that the [Bats Test Framework](https://github.com/bats-core/bats-core) is available in the local `test_lib` directory (Bats is included as a Git submodule) and then run the test suite found in the [test](test) folder.
|
|
||||||
The test script will execute each test in turn, and will print a status for each test case.
|
|
||||||
|
|
||||||
When adding new test cases, please take a look at the existing test cases for examples.
|
|
||||||
|
|
||||||
The following libraries are used to help with the tests:
|
|
||||||
|
|
||||||
* Test Framework: https://github.com/bats-core/bats-core
|
|
||||||
* Support library for Bats-Assert: https://github.com/ztombol/bats-support
|
|
||||||
* General `assert` functions: https://github.com/ztombol/bats-assert
|
|
||||||
* File `assert` functions: https://github.com/ztombol/bats-file
|
|
||||||
|
|
||||||
When verifying test results, please try to use the `assert` functions found in these libraries.
|
|
||||||
|
|
||||||
## Features
|
|
||||||
|
|
||||||
* When adding new completions or plugins, please don't simply copy existing tools into the Bash-it codebase, try to load/integrate the tools instead.
|
|
||||||
An example is using `nvm`: Instead of copying the existing `nvm` script into Bash-it, the `nvm.plugin.bash` file tries to load an existing installation of `nvm`.
|
|
||||||
This means an additional step for the user (installing `nvm` from its own repo, or through a package manager),
|
|
||||||
but it will also ensure that `nvm` can be upgraded in an easy way.
|
|
||||||
|
|
||||||
## Themes
|
|
||||||
|
|
||||||
* When adding a new theme, please include a screenshot and a short description about what makes this theme unique in the Pull Request's description field.
|
|
||||||
Please do not add theme screenshots to the repo itself, as they will add unnecessary bloat to the repo.
|
|
||||||
The project's Wiki has a _Themes_ page where you can add a screenshot if you want.
|
|
||||||
* Ideally, each theme's folder should contain a `README.md` file describing the theme and its configuration options.
|
|
||||||
|
|
@ -1,66 +0,0 @@
|
||||||
# Bash-it Development
|
|
||||||
|
|
||||||
This page summarizes a couple of rules to keep in mind when developing features or making changes in Bash-it.
|
|
||||||
|
|
||||||
## Debugging and Logging
|
|
||||||
|
|
||||||
### General Logging
|
|
||||||
|
|
||||||
While developing feature or making changes in general, you can log error/warning/debug
|
|
||||||
using `_log_error` `_log_warning` and `_log_debug`. This will help you solve problems quicker
|
|
||||||
and also propagate important notes to other users of Bash-it.
|
|
||||||
You can see the logs by using `bash-it doctor` command to reload and see the logs.
|
|
||||||
Alternatively, you can set `BASH_IT_LOG_LEVEL` to `BASH_IT_LOG_LEVEL_ERROR`, `BASH_IT_LOG_LEVEL_WARNING` or `BASH_IT_LOG_LEVEL_ALL`.
|
|
||||||
|
|
||||||
### Log Prefix/Context
|
|
||||||
|
|
||||||
You can define `BASH_IT_LOG_PREFIX` in your files in order to a have a constant prefix before your logs.
|
|
||||||
Note that we prefer to uses "tags" based logging, i.e `plugins: git: DEBUG: Loading git plugin`.
|
|
||||||
|
|
||||||
|
|
||||||
## Load Order
|
|
||||||
|
|
||||||
### General Load Order
|
|
||||||
|
|
||||||
The main `bash_it.sh` script loads the frameworks individual components in the following order:
|
|
||||||
|
|
||||||
* `lib/composure.bash`
|
|
||||||
* Files in `lib` with the exception of `appearance.bash` - this means that `composure.bash` is loaded again here (possible improvement?)
|
|
||||||
* Enabled `aliases`
|
|
||||||
* Enabled `plugins`
|
|
||||||
* Enabled `completions`
|
|
||||||
* `themes/colors.theme.bash`
|
|
||||||
* `themes/base.theme.bash`
|
|
||||||
* `lib/appearance.bash`, which loads the selected theme
|
|
||||||
* Custom `aliases`
|
|
||||||
* Custom `plugins`
|
|
||||||
* Custom `completions`
|
|
||||||
* Additional custom files from either `$BASH_IT/custom` or `$BASH_IT_CUSTOM`
|
|
||||||
|
|
||||||
This order is subject to change.
|
|
||||||
|
|
||||||
### Individual Component Load Order
|
|
||||||
|
|
||||||
For `aliases`, `plugins` and `completions`, the following rules are applied that influence the load order:
|
|
||||||
|
|
||||||
* There is a global `enabled` directory, which the enabled components are linked into. Enabled plugins are symlinked from `$BASH_IT/plugins/available` to `$BASH_IT/enabled` for example. All component types are linked into the same common `$BASH_IT/enabled` directory.
|
|
||||||
* Within the common `enabled` directories, the files are loaded in alphabetical order, which is based on the item's load priority (see next item).
|
|
||||||
* When enabling a component, a _load priority_ is assigned to the file. The following default priorities are used:
|
|
||||||
* Aliases: 150
|
|
||||||
* Plugins: 250
|
|
||||||
* Completions: 350
|
|
||||||
* When symlinking a component into the `enabled` directory, the load priority is used as a prefix for the linked name, separated with three dashes from the name of the component. The `node.plugin.bash` would be symlinked to `250---node.plugin.bash` for example.
|
|
||||||
* Each file can override the default load priority by specifying a new value. To do this, the file needs to include a comment in the following form. This example would cause the `node.plugin.bash` (if included in that file) to be linked to `225---node.plugin.bash`:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# BASH_IT_LOAD_PRIORITY: 225
|
|
||||||
```
|
|
||||||
|
|
||||||
Having the order based on a numeric priority in a common directory allows for more flexibility. While in general, aliases are loaded first (since their default priority is 150), it's possible to load some aliases after the plugins, or some plugins after completions by setting the items' load priority. This is more flexible than a fixed type-based order or a strict alphabetical order based on name.
|
|
||||||
|
|
||||||
These items are subject to change. When making changes to the internal functionality, this page needs to be updated as well.
|
|
||||||
|
|
||||||
## Plugin Disable Callbacks
|
|
||||||
|
|
||||||
Plugins can define a function that will be called when the plugin is being disabled.
|
|
||||||
The callback name should be `{PLUGIN_NAME}_on_disable`, you can see `gitstatus` for usage example.
|
|
||||||
|
|
@ -0,0 +1,21 @@
|
||||||
|
MIT License
|
||||||
|
|
||||||
|
Copyright (c) 2020-2021 Bash-it
|
||||||
|
|
||||||
|
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.
|
||||||
502
README.md
502
README.md
|
|
@ -1,502 +0,0 @@
|
||||||
# Bash-it
|
|
||||||
|
|
||||||
[](https://travis-ci.com/Bash-it/bash-it)
|
|
||||||
[](https://gitter.im/Bash-it/bash-it?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
|
||||||
|
|
||||||
**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:)
|
|
||||||
|
|
||||||
Includes autocompletion, themes, aliases, custom functions, a few stolen pieces from Steve Losh, and more.
|
|
||||||
|
|
||||||
Bash-it provides a solid framework for using, developing and maintaining shell scripts and custom commands for your daily work.
|
|
||||||
If you're using the _Bourne Again Shell_ (Bash) regularly and have been looking for an easy way on how to keep all of these nice little scripts and aliases under control, then Bash-it is for you!
|
|
||||||
Stop polluting your `~/bin` directory and your `.bashrc` file, fork/clone Bash-it and start hacking away.
|
|
||||||
|
|
||||||
- [Contributing](#contributing)
|
|
||||||
- [Installation](#installation)
|
|
||||||
- [Install Options](#install-options)
|
|
||||||
- [via Docker](#install-using-docker)
|
|
||||||
- [Updating](#updating)
|
|
||||||
- [Help](#help-screens)
|
|
||||||
- [Search](#search)
|
|
||||||
- [Syntax](#syntax)
|
|
||||||
- [Searching with Negations](#searching-with-negations)
|
|
||||||
- [Using Search to Enable or Disable Components](#using-search-to-enable-or-disable-components)
|
|
||||||
- [Disabling ASCII Color](#disabling-ascii-color)
|
|
||||||
- [Custom scripts, aliases, themes, and functions](#custom-scripts-aliases-themes-and-functions)
|
|
||||||
- [Themes](#themes)
|
|
||||||
- [Uninstalling](#uninstalling)
|
|
||||||
- [Misc](#misc)
|
|
||||||
- [Help Out](#help-out)
|
|
||||||
- [Contributors](#contributors)
|
|
||||||
|
|
||||||
## Contributing
|
|
||||||
|
|
||||||
Please take a look at the [Contribution Guidelines](CONTRIBUTING.md) before reporting a bug or providing a new feature.
|
|
||||||
|
|
||||||
The [Development Guidelines](DEVELOPMENT.md) have more information on some of the internal workings of Bash-it,
|
|
||||||
please feel free to read through this page if you're interested in how Bash-it loads its components.
|
|
||||||
|
|
||||||
## Installation
|
|
||||||
|
|
||||||
1. Check out a clone of this repo to a location of your choice, such as
|
|
||||||
`git clone --depth=1 https://github.com/Bash-it/bash-it.git ~/.bash_it`
|
|
||||||
2. Run `~/.bash_it/install.sh` (it automatically backs up your `~/.bash_profile` or `~/.bashrc`, depending on your OS)
|
|
||||||
3. Edit your modified config (`~/.bash_profile` or `~/.bashrc`) file in order to customize Bash-it.
|
|
||||||
4. Check out available aliases, completions, and plugins and enable the ones you want to use (see the next section for more details).
|
|
||||||
|
|
||||||
### Install Options
|
|
||||||
|
|
||||||
The install script can take the following options:
|
|
||||||
|
|
||||||
* `--interactive`: Asks the user which aliases, completions and plugins to enable.
|
|
||||||
* `--silent`: Ask nothing and install using default settings.
|
|
||||||
* `--no-modify-config`: Do not modify the existing config file (`~/.bash_profile` or `~/.bashrc`).
|
|
||||||
|
|
||||||
When run without the `--interactive` switch, Bash-it only enables a sane default set of functionality to keep your shell clean and to avoid issues with missing dependencies.
|
|
||||||
Feel free to enable the tools you want to use after the installation.
|
|
||||||
|
|
||||||
When you run without the `--no-modify-config` switch, the Bash-it installer automatically modifies/replaces your existing config file.
|
|
||||||
Use the `--no-modify-config` switch to avoid unwanted modifications, e.g. if your Bash config file already contains the code that loads Bash-it.
|
|
||||||
|
|
||||||
**NOTE**: Keep in mind how Bash loads its configuration files,
|
|
||||||
`.bash_profile` for login shells (and in macOS in terminal emulators like [Terminal.app](http://www.apple.com/osx/apps/) or
|
|
||||||
[iTerm2](https://www.iterm2.com/)) and `.bashrc` for interactive shells (default mode in most of the GNU/Linux terminal emulators),
|
|
||||||
to ensure that Bash-it is loaded correctly.
|
|
||||||
A good "practice" is sourcing `.bashrc` into `.bash_profile` to keep things working in all the scenarios.
|
|
||||||
To achieve this, you can add this snippet in your `.bash_profile`:
|
|
||||||
|
|
||||||
```
|
|
||||||
if [ -f ~/.bashrc ]; then
|
|
||||||
. ~/.bashrc
|
|
||||||
fi
|
|
||||||
```
|
|
||||||
|
|
||||||
Refer to the official [Bash documentation](https://www.gnu.org/software/bash/manual/bashref.html#Bash-Startup-Files) to get more info.
|
|
||||||
|
|
||||||
|
|
||||||
### Install using Docker
|
|
||||||
|
|
||||||
You can try Bash-it in an isolated environment without changing any local files via a [Docker](https://www.docker.com/) Container.
|
|
||||||
(Bash Shell v4.4 with Bash-it, [bats](https://github.com/sstephenson/bats),and bash-completion based on [Alpine Linux](https://alpinelinux.org/)).
|
|
||||||
|
|
||||||
`docker pull ellerbrock/bash-it`
|
|
||||||
|
|
||||||
Have a look at our [bash-it-docker repository](https://github.com/Bash-it/bash-it-docker) for further information.
|
|
||||||
|
|
||||||
|
|
||||||
### Updating
|
|
||||||
|
|
||||||
To update Bash-it to the latest stable version, simply run:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
bash-it update stable
|
|
||||||
```
|
|
||||||
|
|
||||||
If you want to update to the latest dev version (directly from master), run:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
bash-it update dev
|
|
||||||
```
|
|
||||||
|
|
||||||
If you want to update automatically and unattended, you can add the optional
|
|
||||||
`-s/--silent` flag, for example:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
bash-it update dev --silent
|
|
||||||
```
|
|
||||||
|
|
||||||
If you are using an older version of Bash-it, it's possible that some functionality has changed, or that the internal structure of how Bash-it organizes its functionality has been updated.
|
|
||||||
For these cases, we provide a `migrate` command:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
bash-it migrate
|
|
||||||
```
|
|
||||||
|
|
||||||
This command will automatically migrate the Bash-it structure to the latest version.
|
|
||||||
The `migrate` command is run automatically if you run the `update`, `enable` or `disable` commands.
|
|
||||||
|
|
||||||
## Help Screens
|
|
||||||
|
|
||||||
```bash
|
|
||||||
bash-it show aliases # shows installed and available aliases
|
|
||||||
bash-it show completions # shows installed and available completions
|
|
||||||
bash-it show plugins # shows installed and available plugins
|
|
||||||
bash-it help aliases # shows help for installed aliases
|
|
||||||
bash-it help completions # shows help for installed completions
|
|
||||||
bash-it help plugins # shows help for installed plugins
|
|
||||||
```
|
|
||||||
|
|
||||||
## Search
|
|
||||||
|
|
||||||
If you need to quickly find out which of the plugins, aliases or completions are available for a specific framework, programming language, or an environment, you can _search_ for multiple terms related to the commands you use frequently.
|
|
||||||
Search will find and print out modules with the name or description matching the terms provided.
|
|
||||||
|
|
||||||
### Syntax
|
|
||||||
|
|
||||||
```bash
|
|
||||||
bash-it search term1 [[-]term2] [[-]term3]....
|
|
||||||
```
|
|
||||||
|
|
||||||
As an example, a ruby developer might want to enable everything related to the commands such as `ruby`, `rake`, `gem`, `bundler`, and `rails`.
|
|
||||||
Search command helps you find related modules so that you can decide which of them you'd like to use:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
❯ bash-it search ruby rake gem bundle irb rails
|
|
||||||
aliases: bundler rails
|
|
||||||
plugins: chruby chruby-auto ruby
|
|
||||||
completions: bundler gem rake
|
|
||||||
```
|
|
||||||
|
|
||||||
Currently enabled modules will be shown in green.
|
|
||||||
|
|
||||||
### Searching with Negations
|
|
||||||
|
|
||||||
You can prefix a search term with a "-" to exclude it from the results.
|
|
||||||
In the above example, if we wanted to hide `chruby` and `chruby-auto`,
|
|
||||||
we could change the command as follows:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
❯ bash-it search ruby rake gem bundle irb rails -chruby
|
|
||||||
aliases: bundler rails
|
|
||||||
plugins: ruby
|
|
||||||
completions: bundler gem rake
|
|
||||||
```
|
|
||||||
|
|
||||||
### Using Search to Enable or Disable Components
|
|
||||||
|
|
||||||
By adding a `--enable` or `--disable` to the search command, you can automatically enable all modules that come up as a result of a search query.
|
|
||||||
This could be quite handy if you like to enable a bunch of components related to the same topic.
|
|
||||||
|
|
||||||
### Disabling ASCII Color
|
|
||||||
|
|
||||||
To remove non-printing non-ASCII characters responsible for the coloring of the search output, you can set environment variable `NO_COLOR`.
|
|
||||||
Enabled components will then be shown with a checkmark:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
❯ NO_COLOR=1 bash-it search ruby rake gem bundle irb rails -chruby
|
|
||||||
aliases => ✓bundler ✓rails
|
|
||||||
plugins => ✓ruby
|
|
||||||
completions => bundler gem rake
|
|
||||||
```
|
|
||||||
|
|
||||||
## Custom scripts, aliases, themes, and functions
|
|
||||||
|
|
||||||
For custom scripts, and aliases, just create the following files (they'll be ignored by the git repo):
|
|
||||||
|
|
||||||
* `aliases/custom.aliases.bash`
|
|
||||||
* `completion/custom.completion.bash`
|
|
||||||
* `lib/custom.bash`
|
|
||||||
* `plugins/custom.plugins.bash`
|
|
||||||
* `custom/themes/<custom theme name>/<custom theme name>.theme.bash`
|
|
||||||
|
|
||||||
Anything in the custom directory will be ignored, with the exception of `custom/example.bash`.
|
|
||||||
|
|
||||||
Alternately, if you would like to keep your custom scripts under version control, you can set `BASH_IT_CUSTOM` in your `~/.bashrc` to another location outside of the `$BASH_IT` folder.
|
|
||||||
In this case, any `*.bash` file under every directory below `BASH_IT_CUSTOM` folder will be used.
|
|
||||||
|
|
||||||
## Themes
|
|
||||||
|
|
||||||
There are over 50+ Bash-it themes to pick from in `$BASH_IT/themes`.
|
|
||||||
The default theme is `bobby`.
|
|
||||||
Set `BASH_IT_THEME` to the theme name you want, or if you've developed your own custom theme outside of `$BASH_IT/themes`,
|
|
||||||
point the `BASH_IT_THEME` variable directly to the theme file.
|
|
||||||
To disable theming completely, leave the variable empty.
|
|
||||||
|
|
||||||
Examples:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Use the "powerline-multiline" theme
|
|
||||||
export BASH_IT_THEME="powerline-multiline"
|
|
||||||
|
|
||||||
# Use a theme outside of the Bash-it folder
|
|
||||||
export BASH_IT_THEME="/home/foo/my_theme/my_theme.theme.bash"
|
|
||||||
|
|
||||||
# Disable theming
|
|
||||||
export BASH_IT_THEME=""
|
|
||||||
```
|
|
||||||
|
|
||||||
You can easily preview the themes in your own shell using `BASH_PREVIEW=true bash-it reload`.
|
|
||||||
|
|
||||||
If you've created your own custom prompts, we'd love it if you shared them with everyone else! Just submit a Pull Request.
|
|
||||||
You can see theme screenshots on [wiki/Themes](https://github.com/Bash-it/bash-it/wiki/Themes).
|
|
||||||
|
|
||||||
**NOTE**: Bash-it and some themes use UTF-8 characters, so to avoid strange behavior in your terminal, set your locale to `LC_ALL=en_US.UTF-8` or the equivalent to your language if it isn't American English.
|
|
||||||
|
|
||||||
## Uninstalling
|
|
||||||
|
|
||||||
To uninstall Bash-it, run the `uninstall.sh` script found in the `$BASH_IT` directory:
|
|
||||||
|
|
||||||
```
|
|
||||||
cd $BASH_IT
|
|
||||||
./uninstall.sh
|
|
||||||
```
|
|
||||||
|
|
||||||
This will restore your previous Bash profile.
|
|
||||||
After the uninstall script finishes, remove the Bash-it directory from your machine (`rm -rf $BASH_IT`) and start a new shell.
|
|
||||||
|
|
||||||
## Misc
|
|
||||||
|
|
||||||
### Bash Profile Aliases
|
|
||||||
|
|
||||||
Bash-it creates a `reload` alias that makes it convenient to reload
|
|
||||||
your Bash profile when you make changes.
|
|
||||||
|
|
||||||
Additionally, if you export `BASH_IT_AUTOMATIC_RELOAD_AFTER_CONFIG_CHANGE` as a non-null value,
|
|
||||||
Bash-it will automatically reload itself after activating or deactivating plugins, aliases, or completions.
|
|
||||||
|
|
||||||
### Prompt Version Control Check
|
|
||||||
|
|
||||||
Bash-it provides prompt themes with the ability to check and display version control information for the current directory.
|
|
||||||
The information is retrieved for each directory and can slow down the navigation of projects with a large number of files and folders.
|
|
||||||
Turn version control checking off to prevent slow directory navigation within large projects.
|
|
||||||
|
|
||||||
Bash-it provides a flag (`SCM_CHECK`) within the `~/.bash_profile` file that turns off/on version control information checking and display within all themes.
|
|
||||||
Version control checking is on by default unless explicitly turned off.
|
|
||||||
|
|
||||||
Set `SCM_CHECK` to 'false' to **turn off** version control checks for all themes:
|
|
||||||
|
|
||||||
* `export SCM_CHECK=false`
|
|
||||||
|
|
||||||
Set `SCM_CHECK` to 'true' (the default value) to **turn on** version control checks for all themes:
|
|
||||||
|
|
||||||
* `export SCM_CHECK=true`
|
|
||||||
|
|
||||||
**NOTE:**
|
|
||||||
It is possible for themes to ignore the `SCM_CHECK` flag and query specific version control information directly.
|
|
||||||
For example, themes that use functions like `git_prompt_vars` skip the `SCM_CHECK` flag to retrieve and display git prompt information.
|
|
||||||
If you turned version control checking off and you still see version control information within your prompt, then functions like `git_prompt_vars` are most likely the reason why.
|
|
||||||
|
|
||||||
### Git prompt
|
|
||||||
|
|
||||||
Bash-it has some nice features related to Git, continue reading to know more about these features.
|
|
||||||
|
|
||||||
### Repository info in the prompt
|
|
||||||
|
|
||||||
Bash-it can show some information about Git repositories in the shell prompt: the current branch, tag or commit you are at, how many commits the local branch is ahead or behind from the remote branch, and if you have changes stashed.
|
|
||||||
|
|
||||||
Additionally, you can view the status of your working copy and get the count of *staged*, *unstaged* and *untracked* files.
|
|
||||||
This feature is controlled through the flag `SCM_GIT_SHOW_DETAILS` as follows:
|
|
||||||
|
|
||||||
Set `SCM_GIT_SHOW_DETAILS` to 'true' (the default value) to **show** the working copy details in your prompt:
|
|
||||||
|
|
||||||
* `export SCM_GIT_SHOW_DETAILS=true`
|
|
||||||
|
|
||||||
Set `SCM_GIT_SHOW_DETAILS` to 'false' to **don't show** it:
|
|
||||||
|
|
||||||
* `export SCM_GIT_SHOW_DETAILS=false`
|
|
||||||
|
|
||||||
**NOTE:** If using `SCM_GIT_SHOW_MINIMAL_INFO=true`, then the value of `SCM_GIT_SHOW_DETAILS` is ignored.
|
|
||||||
|
|
||||||
### Remotes and remote branches
|
|
||||||
|
|
||||||
In some git workflows, you must work with various remotes, for this reason, Bash-it can provide some useful information about your remotes and your remote branches, for example, the remote on you are working, or if your local branch is tracking a remote branch.
|
|
||||||
|
|
||||||
You can control this feature with the flag `SCM_GIT_SHOW_REMOTE_INFO` as follows:
|
|
||||||
|
|
||||||
Set `SCM_GIT_SHOW_REMOTE_INFO` to 'auto' (the default value) to activate it only when more than one remote is configured in the current repo:
|
|
||||||
|
|
||||||
* `export SCM_GIT_SHOW_REMOTE_INFO=auto`
|
|
||||||
|
|
||||||
Set `SCM_GIT_SHOW_REMOTE_INFO` to 'true' to always activate the feature:
|
|
||||||
|
|
||||||
* `export SCM_GIT_SHOW_REMOTE_INFO=true`
|
|
||||||
|
|
||||||
Set `SCM_GIT_SHOW_REMOTE_INFO` to 'false' to **disable the feature**:
|
|
||||||
|
|
||||||
* `export SCM_GIT_SHOW_REMOTE_INFO=false`
|
|
||||||
|
|
||||||
**NOTE:** If using `SCM_GIT_SHOW_MINIMAL_INFO=true`, then the value of `SCM_GIT_SHOW_REMOTE_INFO` is ignored.
|
|
||||||
|
|
||||||
### Untracked files
|
|
||||||
|
|
||||||
By default, the `git status` command shows information about *untracked* files.
|
|
||||||
This behavior can be controlled through command-line flags or git configuration files.
|
|
||||||
For big repositories, ignoring *untracked* files can make git faster.
|
|
||||||
Bash-it uses `git status` to gather the repo information it shows in the prompt, so in some circumstances, it can be useful to instruct Bash-it to ignore these files.
|
|
||||||
You can control this behavior with the flag `SCM_GIT_IGNORE_UNTRACKED`:
|
|
||||||
|
|
||||||
Set `SCM_GIT_IGNORE_UNTRACKED` to 'false' (the default value) to get information about *untracked* files:
|
|
||||||
|
|
||||||
* `export SCM_GIT_IGNORE_UNTRACKED=false`
|
|
||||||
|
|
||||||
Set `SCM_GIT_IGNORE_UNTRACKED` to 'true' to **ignore** *untracked* files:
|
|
||||||
|
|
||||||
* `export SCM_GIT_IGNORE_UNTRACKED=true`
|
|
||||||
|
|
||||||
Also, with this flag to false, Bash-it will not show the repository as dirty when the repo has *untracked* files, and will not display the count of *untracked* files.
|
|
||||||
|
|
||||||
**NOTE:** If you set in git configuration file the option to ignore *untracked* files, this flag has no effect, and Bash-it will ignore *untracked* files always.
|
|
||||||
|
|
||||||
### Stash item count
|
|
||||||
|
|
||||||
When `SCM_GIT_SHOW_DETAILS` is enabled, you can get the count of *stashed* items. This feature can be useful when a user has a lot of stash items.
|
|
||||||
This feature is controlled through the flag `SCM_GIT_SHOW_STASH_INFO` as follows:
|
|
||||||
|
|
||||||
Set `SCM_GIT_SHOW_STASH_INFO` to 'true' (the default value) to **show** the count of stashed items:
|
|
||||||
|
|
||||||
* `export SCM_GIT_SHOW_STASH_INFO=true`
|
|
||||||
|
|
||||||
Set `SCM_GIT_SHOW_STASH_INFO` to 'false' to **don't show** it:
|
|
||||||
|
|
||||||
* `export SCM_GIT_SHOW_STASH_INFO=false`
|
|
||||||
|
|
||||||
### Ahead/Behind Count
|
|
||||||
|
|
||||||
When displaying information regarding whether or not the local branch is ahead or behind its remote counterpart, you can opt to display the number of commits ahead/behind.
|
|
||||||
This is useful if you only care whether or not you are ahead or behind and do not care how far ahead/behind you are.
|
|
||||||
|
|
||||||
Set `SCM_GIT_SHOW_COMMIT_COUNT` to 'true' (the default value) to **show** the count of commits ahead/behind:
|
|
||||||
|
|
||||||
* `export SCM_GIT_SHOW_COMMIT_COUNT=true`
|
|
||||||
|
|
||||||
Set `SCM_GIT_SHOW_COMMIT_COUNT` to 'false' to **don't show** it:
|
|
||||||
|
|
||||||
* `export SCM_GIT_SHOW_COMMIT_COUNT=false`
|
|
||||||
|
|
||||||
### Git user
|
|
||||||
|
|
||||||
In some environments, it is useful to know the value of the current git user, which is used to mark all new commits.
|
|
||||||
For example, any organization that uses the practice of pair programming will typically author each commit with [combined names of the two authors](https://github.com/pivotal/git_scripts).
|
|
||||||
When another pair uses the same pairing station, the authors are changed at the beginning of the session.
|
|
||||||
|
|
||||||
To get up and running with this technique, run `gem install pivotal_git_scripts`, and then edit your `~/.pairs` file, according to the specification on the [gem's homepage](https://github.com/pivotal/git_scripts).
|
|
||||||
After that, you should be able to run `git pair kg as` to set the author to, eg. "Konstantin Gredeskoul and Alex Saxby", assuming they've been added to the `~/.pairs` file.
|
|
||||||
Please see gem's documentation for more information.
|
|
||||||
|
|
||||||
To enable the display of the current pair in the prompt, you must set `SCM_GIT_SHOW_CURRENT_USER` to `true`.
|
|
||||||
Once set, the `SCM_CURRENT_USER` variable will be automatically populated with the initials of the git author(s).
|
|
||||||
It will also be included in the default git prompt.
|
|
||||||
Even if you do not have `git pair` installed, as long as your `user.name` is set, your initials will be computed from your name and shown in the prompt.
|
|
||||||
|
|
||||||
You can control the prefix and the suffix of this component using the two variables:
|
|
||||||
|
|
||||||
* `export SCM_THEME_CURRENT_USER_PREFFIX=' ☺︎ '`
|
|
||||||
|
|
||||||
And
|
|
||||||
|
|
||||||
* `export SCM_THEME_CURRENT_USER_SUFFIX=' ☺︎ '`
|
|
||||||
|
|
||||||
**NOTE:** If using `SCM_GIT_SHOW_MINIMAL_INFO=true`, then the value of `SCM_GIT_SHOW_CURRENT_USER` is ignored.
|
|
||||||
|
|
||||||
### Git show minimal status info
|
|
||||||
|
|
||||||
To speed up the prompt while still getting minimal git status information displayed such as the value of `HEAD` and whether there are any dirty objects, you can set:
|
|
||||||
|
|
||||||
```
|
|
||||||
export SCM_GIT_SHOW_MINIMAL_INFO=true
|
|
||||||
```
|
|
||||||
|
|
||||||
### Ignore repo status
|
|
||||||
|
|
||||||
When working in repos with a large codebase, Bash-it can slow down your prompt when checking the repo status.
|
|
||||||
To avoid it, there is an option you can set via Git config to disable checking repo status in Bash-it.
|
|
||||||
|
|
||||||
To disable checking the status in the current repo:
|
|
||||||
|
|
||||||
```
|
|
||||||
$ git config --add bash-it.hide-status 1
|
|
||||||
```
|
|
||||||
|
|
||||||
But if you would like to disable it globally, and stop checking the status for all of your repos:
|
|
||||||
|
|
||||||
```
|
|
||||||
$ git config --global --add bash-it.hide-status 1
|
|
||||||
```
|
|
||||||
|
|
||||||
Setting this flag globally has the same effect as `SCM_CHECK=true`, but only for Git repos.
|
|
||||||
|
|
||||||
### Speed up git status calculations
|
|
||||||
|
|
||||||
As an alternative to ignoring repo status entirely, you can try out the `gitstatus` plugin.
|
|
||||||
This plugin speeds up all `git status` calculations by up to 10x times!
|
|
||||||
|
|
||||||
**NOTE**: You will need to clone `gitstatus` repo from [here](https://github.com/romkatv/gitstatus).
|
|
||||||
|
|
||||||
### Pass function renamed to passgen
|
|
||||||
|
|
||||||
The Bash-it `pass` function has been renamed to `passgen` in order to avoid a naming conflict with the [pass password manager](https://www.passwordstore.org/).
|
|
||||||
In order to minimize the impact on users of the legacy Bash-it `pass` function, Bash-it will create the alias `pass` that calls the new `passgen` function if the `pass` password manager command is not found on the `PATH` (default behavior).
|
|
||||||
|
|
||||||
This behavior can be overridden with the `BASH_IT_LEGACY_PASS` flag as follows:
|
|
||||||
|
|
||||||
Set `BASH_IT_LEGACY_PASS` to 'true' to force Bash-it to always **create** the `pass` alias to `passgen`:
|
|
||||||
|
|
||||||
* `export BASH_IT_LEGACY_PASS=true`
|
|
||||||
|
|
||||||
Unset `BASH_IT_LEGACY_PASS` to have Bash-it **return to default behavior**:
|
|
||||||
|
|
||||||
* `unset BASH_IT_LEGACY_PASS`
|
|
||||||
|
|
||||||
### Debugging
|
|
||||||
|
|
||||||
If you encounter problems with any part of Bash-it, run the following command:
|
|
||||||
```bash
|
|
||||||
bash-it doctor
|
|
||||||
```
|
|
||||||
This will reload your bash profile and print out logs of various parts in Bash-it.
|
|
||||||
Note that this command at default will print all logs, including debug logs.
|
|
||||||
You can call it like this:
|
|
||||||
```bash
|
|
||||||
bash-it doctor [errors/warnings/all]
|
|
||||||
```
|
|
||||||
In order to get wanted verbosity.
|
|
||||||
|
|
||||||
### Proxy Support
|
|
||||||
|
|
||||||
If you are working in a corporate environment where you have to go through a proxy server for internet access,
|
|
||||||
then you know how painful it is to configure the OS proxy variables in the shell,
|
|
||||||
especially if you are switching between environments, e.g. office (with proxy) and home (without proxy).
|
|
||||||
|
|
||||||
The Bash shell (and many shell tools) use the following variables to define the proxy to use:
|
|
||||||
|
|
||||||
* `HTTP_PROXY` (and `http_proxy`): Defines the proxy server for HTTP requests
|
|
||||||
* `HTTPS_PROXY` (and `https_proxy`): Defines the proxy server for HTTPS requests
|
|
||||||
* `ALL_PROXY` (and `all_proxy`): Used by some tools for the same purpose as above
|
|
||||||
* `NO_PROXY` (and `no_proxy`): Comma-separated list of hostnames that don't have to go through the proxy
|
|
||||||
|
|
||||||
Bash-it's `proxy` plugin allows to enable and disable these variables with a simple command.
|
|
||||||
To start using the `proxy` plugin, run the following:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
bash-it enable plugin proxy
|
|
||||||
```
|
|
||||||
|
|
||||||
Bash-it also provides support for enabling/disabling proxy settings for various shell tools.
|
|
||||||
The following backends are currently supported (in addition to the shell's environment variables): Git, SVN, npm, ssh.
|
|
||||||
The `proxy` plugin changes the configuration files of these tools to enable or disable the proxy settings.
|
|
||||||
|
|
||||||
Bash-it uses the following variables to set the shell's proxy settings when you call `enable-proxy`.
|
|
||||||
These variables are best defined in a custom script in Bash-it's custom script folder (`$BASH_IT/custom`), e.g. `$BASH_IT/custom/proxy.env.bash`
|
|
||||||
* `BASH_IT_HTTP_PROXY` and `BASH_IT_HTTPS_PROXY`: Define the proxy URL to be used, e.g. 'http://localhost:1234'
|
|
||||||
* `BASH_IT_NO_PROXY`: A comma-separated list of proxy exclusions, e.g. `127.0.0.1,localhost`
|
|
||||||
|
|
||||||
Once you have defined these variables (and have run `reload` to load the changes), you can use the following commands to enable or disable the proxy settings in your current shell:
|
|
||||||
|
|
||||||
* `enable-proxy`: This sets the shell's proxy environment variables and configures proxy support in your SVN, npm, and SSH configuration files.
|
|
||||||
* `disable-proxy`: This unsets the shell's proxy environment variables and disables proxy support in your SVN, npm, and SSH configuration files.
|
|
||||||
|
|
||||||
There are many more proxy commands, e.g. for changing the local Git project's proxy settings.
|
|
||||||
Run `glossary proxy` to show the available proxy functions with a short description.
|
|
||||||
|
|
||||||
## Help out
|
|
||||||
|
|
||||||
We think everyone has their own custom scripts accumulated over time.
|
|
||||||
And so, following in the footsteps of oh-my-zsh, Bash-it is a framework for easily customizing your Bash shell.
|
|
||||||
Everyone's got a custom toolbox, so let's start making them even better, **as a community!**
|
|
||||||
|
|
||||||
Send us a pull request and we'll merge it as long as it looks good.
|
|
||||||
If you change an existing command, please give an explanation why.
|
|
||||||
That will help a lot when we merge your changes in.
|
|
||||||
|
|
||||||
Please take a look at the [Contribution Guidelines](CONTRIBUTING.md) before reporting a bug or providing a new feature.
|
|
||||||
|
|
||||||
Thanks, and happing bashing!
|
|
||||||
|
|
||||||
|
|
||||||
## Contributors
|
|
||||||
|
|
||||||
* [List of contributors][contribute]
|
|
||||||
|
|
||||||
[contribute]: https://github.com/Bash-it/bash-it/contributors
|
|
||||||
[pass password manager]: http://www.passwordstore.org/
|
|
||||||
|
|
@ -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,20 +1,16 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'pbcopy and pbpaste shortcuts to linux'
|
about-alias 'xclip shortcuts'
|
||||||
|
|
||||||
case $OSTYPE in
|
alias pbcopy="xclip -selection clipboard"
|
||||||
linux*)
|
alias pbpaste="xclip -selection clipboard -o"
|
||||||
XCLIP=$(command -v xclip)
|
|
||||||
[[ $XCLIP ]] && \
|
|
||||||
alias pbcopy="$XCLIP -selection clipboard" && \
|
|
||||||
alias pbpaste="$XCLIP -selection clipboard -o"
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
|
alias xcpy="xclip -selection clipboard"
|
||||||
|
alias xpst="xclip -selection clipboard -o"
|
||||||
# to use it just install xclip on your distribution and it would work like:
|
# to use it just install xclip on your distribution and it would work like:
|
||||||
# $ echo "hello" | pbcopy
|
# $ echo "hello" | xcpy
|
||||||
# $ pbpaste
|
# $ xpst
|
||||||
# hello
|
# hello
|
||||||
|
|
||||||
# very useful for things like:
|
# very useful for things like:
|
||||||
# cat ~/.ssh/id_rsa.pub | pbcopy
|
# cat ~/.ssh/id_rsa.pub | xcpy
|
||||||
# have fun!
|
# have fun!
|
||||||
|
|
|
||||||
|
|
@ -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
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
about-alias 'dnf aliases for fedora 22+ distros'
|
||||||
|
|
||||||
|
alias dnfl="dnf list" # List packages
|
||||||
|
alias dnfli="dnf list installed" # List installed packages
|
||||||
|
alias dnfgl="dnf grouplist" # List package groups
|
||||||
|
alias dnfmc="dnf makecache" # Generate metadata cache
|
||||||
|
alias dnfp="dnf info" # Show package information
|
||||||
|
alias dnfs="dnf search" # Search package
|
||||||
|
|
||||||
|
alias dnfu="sudo dnf upgrade" # Upgrade package
|
||||||
|
alias dnfi="sudo dnf install" # Install package
|
||||||
|
alias dnfri='sudo dnf reinstall' # Reinstall package
|
||||||
|
alias dnfgi="sudo dnf groupinstall" # Install package group
|
||||||
|
alias dnfr="sudo dnf remove" # Remove package
|
||||||
|
alias dnfgr="sudo dnf groupremove" # Remove package group
|
||||||
|
alias dnfc="sudo dnf clean all" # Clean cache
|
||||||
|
|
@ -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,11 +1,10 @@
|
||||||
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
|
||||||
alias fucking=sudo
|
alias fucking=sudo
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -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,131 +1,212 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'common git abbreviations'
|
about-alias 'common git abbreviations'
|
||||||
|
|
||||||
# Aliases
|
|
||||||
alias gcl='git clone'
|
|
||||||
alias ga='git add'
|
|
||||||
alias grm='git rm'
|
|
||||||
alias gap='git add -p'
|
|
||||||
alias gall='git add -A'
|
|
||||||
alias gf='git fetch --all --prune'
|
|
||||||
alias gft='git fetch --all --prune --tags'
|
|
||||||
alias gfv='git fetch --all --prune --verbose'
|
|
||||||
alias gftv='git fetch --all --prune --tags --verbose'
|
|
||||||
alias gus='git reset HEAD'
|
|
||||||
alias gpristine='git reset --hard && git clean -dfx'
|
|
||||||
alias gclean='git clean -fd'
|
|
||||||
alias gm="git merge"
|
|
||||||
alias gmv='git mv'
|
|
||||||
alias g='git'
|
alias g='git'
|
||||||
alias get='git'
|
alias get='git'
|
||||||
alias gs='git status'
|
|
||||||
alias gss='git status -s'
|
# add
|
||||||
alias gsu='git submodule update --init --recursive'
|
alias ga='git add'
|
||||||
alias gl='git pull'
|
alias gall='git add -A'
|
||||||
alias gpl='git pull'
|
alias gap='git add -p'
|
||||||
alias glum='git pull upstream master'
|
alias gav='git add -v'
|
||||||
alias gpr='git pull --rebase'
|
|
||||||
alias gpp='git pull && git push'
|
# branch
|
||||||
alias gup='git fetch && git rebase'
|
alias gb='git branch'
|
||||||
alias gp='git push'
|
alias gba='git branch --all'
|
||||||
alias gpo='git push origin HEAD'
|
alias gbd='git branch -d'
|
||||||
alias gpu='git push --set-upstream'
|
alias gbD='git branch -D'
|
||||||
alias gpuo='git push --set-upstream origin'
|
alias gbl='git branch --list'
|
||||||
alias gpuoc='git push --set-upstream origin $(git symbolic-ref --short HEAD)'
|
alias gbla='git branch --list --all'
|
||||||
alias gpom='git push origin master'
|
alias gblr='git branch --list --remotes'
|
||||||
alias gr='git remote'
|
alias gbm='git branch --move'
|
||||||
alias grv='git remote -v'
|
alias gbr='git branch --remotes'
|
||||||
alias gra='git remote add'
|
alias gbt='git branch --track'
|
||||||
alias grb='git rebase'
|
alias gdel='git branch -D'
|
||||||
alias grm='git rebase master'
|
|
||||||
alias grmi='git rebase master -i'
|
# for-each-ref
|
||||||
|
alias gbc='git for-each-ref --format="%(authorname) %09 %(if)%(HEAD)%(then)*%(else)%(refname:short)%(end) %09 %(creatordate)" refs/remotes/ --sort=authorname DESC' # FROM https://stackoverflow.com/a/58623139/10362396
|
||||||
|
|
||||||
|
# commit
|
||||||
|
alias gc='git commit -v'
|
||||||
|
alias gca='git commit -v -a'
|
||||||
|
alias gcaa='git commit -a --amend -C HEAD' # Add uncommitted and unstaged changes to the last commit
|
||||||
|
alias gcam='git commit -v -am'
|
||||||
|
alias gcamd='git commit --amend'
|
||||||
|
alias gcm='git commit -v -m'
|
||||||
|
alias gci='git commit --interactive'
|
||||||
|
alias gcsam='git commit -S -am'
|
||||||
|
|
||||||
|
# checkout
|
||||||
|
alias gcb='git checkout -b'
|
||||||
|
alias gco='git checkout'
|
||||||
|
alias gcob='git checkout -b'
|
||||||
|
alias gcobu='git checkout -b ${USER}/'
|
||||||
|
alias gcom='git checkout $(get_default_branch)'
|
||||||
|
alias gcpd='git checkout $(get_default_branch); git pull; git branch -D'
|
||||||
|
alias gct='git checkout --track'
|
||||||
|
|
||||||
|
# clone
|
||||||
|
alias gcl='git clone'
|
||||||
|
|
||||||
|
# clean
|
||||||
|
alias gclean='git clean -fd'
|
||||||
|
|
||||||
|
# cherry-pick
|
||||||
|
alias gcp='git cherry-pick'
|
||||||
|
alias gcpx='git cherry-pick -x'
|
||||||
|
|
||||||
|
# diff
|
||||||
alias gd='git diff'
|
alias gd='git diff'
|
||||||
alias gds='git diff --staged'
|
alias gds='git diff --staged'
|
||||||
alias gdt='git difftool'
|
alias gdt='git difftool'
|
||||||
alias gdv='git diff -w "$@" | vim -R -'
|
|
||||||
alias gc='git commit -v'
|
# archive
|
||||||
alias gca='git commit -v -a'
|
|
||||||
alias gcm='git commit -v -m'
|
|
||||||
alias gcam="git commit -v -am"
|
|
||||||
alias gci='git commit --interactive'
|
|
||||||
alias gcamd='git commit --amend'
|
|
||||||
alias gb='git branch'
|
|
||||||
alias gba='git branch -a'
|
|
||||||
# FROM https://stackoverflow.com/a/58623139/10362396
|
|
||||||
alias gbc='git for-each-ref --format="%(authorname) %09 %(if)%(HEAD)%(then)*%(else)%(refname:short)%(end) %09 %(creatordate)" refs/remotes/ --sort=authorname DESC'
|
|
||||||
alias gbt='git branch --track'
|
|
||||||
alias gbm='git branch -m'
|
|
||||||
alias gbd='git branch -d'
|
|
||||||
alias gbD='git branch -D'
|
|
||||||
alias gcount='git shortlog -sn'
|
|
||||||
alias gcp='git cherry-pick'
|
|
||||||
alias gcpx='git cherry-pick -x'
|
|
||||||
alias gco='git checkout'
|
|
||||||
alias gcom='git checkout master'
|
|
||||||
alias gcb='git checkout -b'
|
|
||||||
alias gcob='git checkout -b'
|
|
||||||
alias gct='git checkout --track'
|
|
||||||
alias gcpd='git checkout master; git pull; git branch -D'
|
|
||||||
alias gexport='git archive --format zip --output'
|
alias gexport='git archive --format zip --output'
|
||||||
alias gdel='git branch -D'
|
|
||||||
alias gmu='git fetch origin -v; git fetch upstream -v; git merge upstream/master'
|
# fetch
|
||||||
|
alias gf='git fetch --all --prune'
|
||||||
|
alias gft='git fetch --all --prune --tags'
|
||||||
|
alias gftv='git fetch --all --prune --tags --verbose'
|
||||||
|
alias gfv='git fetch --all --prune --verbose'
|
||||||
|
alias gmu='git fetch origin -v; git fetch upstream -v; git merge upstream/$(get_default_branch)'
|
||||||
|
alias gup='git fetch && git rebase'
|
||||||
|
|
||||||
|
# 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 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 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 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 gnew='git log HEAD@{1}..HEAD@{0}' # Show commits since last pull, see http://blogs.atlassian.com/2014/10/advanced-git-aliases/
|
||||||
alias ggf="git log --graph --date=short --pretty=format:'%C(auto)%h %Cgreen%an%Creset %Cblue%cd%Creset %C(auto)%d %s'"
|
alias gwc='git whatchanged'
|
||||||
alias ggs="gg --stat"
|
|
||||||
alias gsh="git show"
|
# ls-files
|
||||||
alias gsl="git shortlog -sn"
|
alias gu='git ls-files . --exclude-standard --others' # Show untracked files
|
||||||
alias gwc="git whatchanged"
|
alias glsut='gu'
|
||||||
alias gt="git tag"
|
alias glsum='git diff --name-only --diff-filter=U' # Show unmerged (conflicted) files
|
||||||
alias gta="git tag -a"
|
|
||||||
alias gtd="git tag -d"
|
# gui
|
||||||
alias gtl="git tag -l"
|
alias ggui='git gui'
|
||||||
alias gpatch="git format-patch -1"
|
|
||||||
# From http://blogs.atlassian.com/2014/10/advanced-git-aliases/
|
# home
|
||||||
# Show commits since last pull
|
alias ghm='cd "$(git rev-parse --show-toplevel)"' # Git home
|
||||||
alias gnew="git log HEAD@{1}..HEAD@{0}"
|
# appendage to ghm
|
||||||
# Add uncommitted and unstaged changes to the last commit
|
|
||||||
alias gcaa="git commit -a --amend -C HEAD"
|
|
||||||
# Rebase with latest remote master
|
|
||||||
alias gprom="git fetch origin master && git rebase origin/master && git update-ref refs/heads/master origin/master"
|
|
||||||
alias gpf="git push --force"
|
|
||||||
alias gpunch="git push --force-with-lease"
|
|
||||||
alias ggui="git gui"
|
|
||||||
alias gcsam="git commit -S -am"
|
|
||||||
# Stash aliases
|
|
||||||
alias gst="git stash"
|
|
||||||
alias gstb="git stash branch"
|
|
||||||
alias gstd="git stash drop"
|
|
||||||
alias gstl="git stash list"
|
|
||||||
# Push introduced in git v2.13.2
|
|
||||||
alias gstpu="git stash push"
|
|
||||||
alias gstpum="git stash push -m"
|
|
||||||
# Save deprecated since git v2.16.0
|
|
||||||
# - aliases now resolve to push
|
|
||||||
alias gsts="git stash push"
|
|
||||||
alias gstsm="git stash push -m"
|
|
||||||
# Alias gstpo added for symmetry with gstpu (push)
|
|
||||||
# - gstp remains as alias for pop due to long-standing usage
|
|
||||||
alias gstpo="git stash pop"
|
|
||||||
alias gstp="git stash pop"
|
|
||||||
# Switch aliases - Requires git v2.23+
|
|
||||||
alias gsw="git switch"
|
|
||||||
alias gswm="git switch master"
|
|
||||||
alias gswc="git switch --create"
|
|
||||||
alias gswt="git switch --track"
|
|
||||||
# Git home
|
|
||||||
alias ghm='cd "$(git rev-parse --show-toplevel)"'
|
|
||||||
if ! _command_exists gh; then
|
if ! _command_exists gh; then
|
||||||
alias gh='ghm'
|
alias gh='ghm'
|
||||||
fi
|
fi
|
||||||
# Show untracked files
|
|
||||||
alias gu='git ls-files . --exclude-standard --others'
|
# merge
|
||||||
|
alias gm='git merge'
|
||||||
|
|
||||||
|
# mv
|
||||||
|
alias gmv='git mv'
|
||||||
|
|
||||||
|
# patch
|
||||||
|
alias gpatch='git format-patch -1'
|
||||||
|
|
||||||
|
# push
|
||||||
|
alias gp='git push'
|
||||||
|
alias gpd='git push --delete'
|
||||||
|
alias gpf='git push --force'
|
||||||
|
alias gpo='git push origin HEAD'
|
||||||
|
alias gpom='git push origin $(get_default_branch)'
|
||||||
|
alias gpu='git push --set-upstream'
|
||||||
|
alias gpunch='git push --force-with-lease'
|
||||||
|
alias gpuo='git push --set-upstream origin'
|
||||||
|
alias gpuoc='git push --set-upstream origin $(git symbolic-ref --short HEAD)'
|
||||||
|
|
||||||
|
# pull
|
||||||
|
alias gl='git pull'
|
||||||
|
alias glum='git pull upstream $(get_default_branch)'
|
||||||
|
alias gpl='git pull'
|
||||||
|
alias gpp='git pull && git push'
|
||||||
|
alias gpr='git pull --rebase'
|
||||||
|
|
||||||
|
# remote
|
||||||
|
alias gr='git remote'
|
||||||
|
alias gra='git remote add'
|
||||||
|
alias grv='git remote -v'
|
||||||
|
|
||||||
|
# rm
|
||||||
|
alias grm='git rm'
|
||||||
|
|
||||||
|
# rebase
|
||||||
|
alias grb='git rebase'
|
||||||
|
alias grbc='git rebase --continue'
|
||||||
|
alias grm='git rebase $(get_default_branch)'
|
||||||
|
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
|
||||||
|
alias gus='git reset HEAD'
|
||||||
|
alias gpristine='git reset --hard && git clean -dfx'
|
||||||
|
|
||||||
|
# status
|
||||||
|
alias gs='git status'
|
||||||
|
alias gss='git status -s'
|
||||||
|
|
||||||
|
# shortlog
|
||||||
|
alias gcount='git shortlog -sn'
|
||||||
|
alias gsl='git shortlog -sn'
|
||||||
|
|
||||||
|
# show
|
||||||
|
alias gsh='git show'
|
||||||
|
|
||||||
|
# svn
|
||||||
|
alias gsd='git svn dcommit'
|
||||||
|
alias gsr='git svn rebase' # Git SVN
|
||||||
|
|
||||||
|
# stash
|
||||||
|
alias gst='git stash'
|
||||||
|
alias gstb='git stash branch'
|
||||||
|
alias gstd='git stash drop'
|
||||||
|
alias gstl='git stash list'
|
||||||
|
alias gstp='git stash pop' # kept due to long-standing usage
|
||||||
|
alias gstpo='git stash pop' # recommended for it's symmetry with gstpu (push)
|
||||||
|
|
||||||
|
## 'stash push' introduced in git v2.13.2
|
||||||
|
alias gstpu='git stash push'
|
||||||
|
alias gstpum='git stash push -m'
|
||||||
|
|
||||||
|
## 'stash save' deprecated since git v2.16.0, alias is now push
|
||||||
|
alias gsts='git stash push'
|
||||||
|
alias gstsm='git stash push -m'
|
||||||
|
|
||||||
|
# submodules
|
||||||
|
alias gsu='git submodule update --init --recursive'
|
||||||
|
|
||||||
|
# switch
|
||||||
|
# these aliases requires git v2.23+
|
||||||
|
alias gsw='git switch'
|
||||||
|
alias gswc='git switch --create'
|
||||||
|
alias gswm='git switch $(get_default_branch)'
|
||||||
|
alias gswt='git switch --track'
|
||||||
|
|
||||||
|
# tag
|
||||||
|
alias gt='git tag'
|
||||||
|
alias gta='git tag -a'
|
||||||
|
alias gtd='git tag -d'
|
||||||
|
alias gtl='git tag -l'
|
||||||
|
|
||||||
case $OSTYPE in
|
case $OSTYPE in
|
||||||
darwin*)
|
darwin*)
|
||||||
alias gtls="git tag -l | gsort -V"
|
alias gtls="git tag -l | gsort -V"
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
alias gtls='git tag -l | sort -V'
|
alias gtls='git tag -l | sort -V'
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
# functions
|
||||||
|
function gdv() {
|
||||||
|
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
|
||||||
|
|
@ -6,4 +6,3 @@ alias node-dev='export NODE_ENV=development'
|
||||||
|
|
||||||
# alias to setup nodejs production environment
|
# alias to setup nodejs production environment
|
||||||
alias node-prod='export NODE_ENV=production'
|
alias node-prod='export NODE_ENV=production'
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -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
|
||||||
|
|
@ -7,4 +7,3 @@ alias puplint="puppet-lint *.pp"
|
||||||
alias pupagt="puppet agent -t"
|
alias pupagt="puppet agent -t"
|
||||||
alias pupagtd="puppet agent -t --debug"
|
alias pupagtd="puppet agent -t --debug"
|
||||||
alias pupapp="puppet apply"
|
alias pupapp="puppet apply"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -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,11 +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'
|
||||||
|
|
@ -13,4 +11,3 @@ alias tgva='terragrunt validate-all'
|
||||||
alias tgpa='terragrunt plan-all'
|
alias tgpa='terragrunt plan-all'
|
||||||
alias tgaa='terragrunt apply-all'
|
alias tgaa='terragrunt apply-all'
|
||||||
alias tgda='terragrunt destroy-all'
|
alias tgda='terragrunt destroy-all'
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -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,19 +1,14 @@
|
||||||
cite 'about-alias'
|
# shellcheck shell=bash
|
||||||
about-alias 'vim abbreviations'
|
about-alias 'vim abbreviations'
|
||||||
|
|
||||||
VIM=$(command -v vim)
|
_command_exists vim || return
|
||||||
GVIM=$(command -v gvim)
|
|
||||||
MVIM=$(command -v mvim)
|
|
||||||
|
|
||||||
[[ -n $VIM ]] && alias v=$VIM
|
alias v='vim'
|
||||||
|
# open the vim help in fullscreen incorporated from
|
||||||
|
# https://stackoverflow.com/a/4687513
|
||||||
|
alias vimh='vim -c ":h | only"'
|
||||||
|
|
||||||
# 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
|
||||||
|
|
|
||||||
194
bash_it.sh
194
bash_it.sh
|
|
@ -1,152 +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" ];
|
: "${CUSTOM_THEME_DIR:="${BASH_IT_CUSTOM}/themes"}"
|
||||||
then
|
: "${BASH_IT_BASHRC:=${BASH_SOURCE[${#BASH_SOURCE[@]} - 1]}}"
|
||||||
# Setting $BASH to maintain backwards compatibility
|
|
||||||
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 source=./lib/composure.bash
|
# shellcheck source-path=SCRIPTDIR/vendor/github.com/erichs/composure
|
||||||
source "${BASH_IT}/lib/composure.bash"
|
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
|
||||||
|
|
||||||
|
# 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
|
for _bash_it_main_file_lib in "${BASH_IT}/lib"/*.bash; do
|
||||||
do
|
[[ "$_bash_it_main_file_lib" == "$APPEARANCE_LIB" ]] && continue
|
||||||
if [ "$_bash_it_config_file" != "$APPEARANCE_LIB" ]; then
|
_bash-it-log-prefix-by-path "${_bash_it_main_file_lib}"
|
||||||
filename=${_bash_it_config_file##*/}
|
_log_debug "Loading library file..."
|
||||||
filename=${filename%.bash}
|
# shellcheck disable=SC1090
|
||||||
BASH_IT_LOG_PREFIX="lib: ${filename}: "
|
source "$_bash_it_main_file_lib"
|
||||||
_log_debug "Loading library file..."
|
BASH_IT_LOG_PREFIX="core: main: "
|
||||||
# shellcheck disable=SC1090
|
|
||||||
source "$_bash_it_config_file"
|
|
||||||
fi
|
|
||||||
done
|
done
|
||||||
|
|
||||||
# Load the global "enabled" directory
|
# Load the global "enabled" directory, then enabled aliases, completion, plugins
|
||||||
# "family" param is empty so that files get sources in glob order
|
# "_bash_it_main_file_type" param is empty so that files get sourced in glob order
|
||||||
# shellcheck source=./scripts/reloader.bash
|
for _bash_it_main_file_type in "" "aliases" "plugins" "completion"; do
|
||||||
source "${BASH_IT}/scripts/reloader.bash"
|
BASH_IT_LOG_PREFIX="core: reloader: "
|
||||||
|
# shellcheck disable=SC2140
|
||||||
# Load enabled aliases, completion, plugins
|
source "${BASH_IT}/scripts/reloader.bash" ${_bash_it_main_file_type:+"skip" "$_bash_it_main_file_type"}
|
||||||
for file_type in "aliases" "plugins" "completion"
|
BASH_IT_LOG_PREFIX="core: main: "
|
||||||
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 [[ ! -z "${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: "
|
BASH_IT_LOG_PREFIX="themes: githelpers: "
|
||||||
# shellcheck source=./themes/colors.theme.bash
|
source "${BASH_IT}/themes/githelpers.theme.bash"
|
||||||
source "${BASH_IT}/themes/colors.theme.bash"
|
BASH_IT_LOG_PREFIX="themes: p4helpers: "
|
||||||
BASH_IT_LOG_PREFIX="themes: githelpers: "
|
source "${BASH_IT}/themes/p4helpers.theme.bash"
|
||||||
# shellcheck source=./themes/githelpers.theme.bash
|
BASH_IT_LOG_PREFIX="themes: base: "
|
||||||
source "${BASH_IT}/themes/githelpers.theme.bash"
|
source "${BASH_IT}/themes/base.theme.bash"
|
||||||
BASH_IT_LOG_PREFIX="themes: p4helpers: "
|
|
||||||
# shellcheck source=./themes/p4helpers.theme.bash
|
|
||||||
source "${BASH_IT}/themes/p4helpers.theme.bash"
|
|
||||||
BASH_IT_LOG_PREFIX="themes: base: "
|
|
||||||
# shellcheck source=./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"
|
for _bash_it_main_file_type in "aliases" "completion" "plugins"; do
|
||||||
do
|
_bash_it_main_file_custom="${BASH_IT}/${_bash_it_main_file_type}/custom.${_bash_it_main_file_type}.bash"
|
||||||
if [ -e "${BASH_IT}/${file_type}/custom.${file_type}.bash" ]
|
if [[ -s "${_bash_it_main_file_custom}" ]]; then
|
||||||
then
|
_bash-it-log-prefix-by-path "${_bash_it_main_file_custom}"
|
||||||
BASH_IT_LOG_PREFIX="${file_type}: custom: "
|
_log_debug "Loading component..."
|
||||||
_log_debug "Loading component..."
|
# shellcheck disable=SC1090
|
||||||
# shellcheck disable=SC1090
|
source "${_bash_it_main_file_custom}"
|
||||||
source "${BASH_IT}/${file_type}/custom.${file_type}.bash"
|
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
|
if [[ -s "${_bash_it_main_file_custom}" ]]; then
|
||||||
do
|
_bash-it-log-prefix-by-path "${_bash_it_main_file_custom}"
|
||||||
if [ -e "${_bash_it_config_file}" ]; then
|
_log_debug "Loading custom file..."
|
||||||
filename=$(basename "${_bash_it_config_file}")
|
# shellcheck disable=SC1090
|
||||||
filename=${filename%*.bash}
|
source "$_bash_it_main_file_custom"
|
||||||
BASH_IT_LOG_PREFIX="custom: $filename: "
|
fi
|
||||||
_log_debug "Loading custom file..."
|
BASH_IT_LOG_PREFIX="core: main: "
|
||||||
# shellcheck disable=SC1090
|
|
||||||
source "$_bash_it_config_file"
|
|
||||||
fi
|
|
||||||
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
|
||||||
|
PREVIEW="gloobus-preview"
|
||||||
if [ -s /usr/bin/gloobus-preview ]; then
|
elif [[ -d /Applications/Preview.app ]]; then
|
||||||
PREVIEW="gloobus-preview"
|
PREVIEW="/Applications/Preview.app"
|
||||||
elif [ -s /Applications/Preview.app ]; then
|
else
|
||||||
# shellcheck disable=SC2034
|
PREVIEW="less"
|
||||||
PREVIEW="/Applications/Preview.app"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# 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_@}"
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,176 @@
|
||||||
|
#######################################################################
|
||||||
|
# Allow-list of files to be lint-checked by CI
|
||||||
|
#
|
||||||
|
# Directory Support
|
||||||
|
# Directory references are allowed within the file, ie:
|
||||||
|
#
|
||||||
|
# themes/powerline
|
||||||
|
#
|
||||||
|
# All files under the referenced directory will be checked
|
||||||
|
#
|
||||||
|
# Checking Files Locally
|
||||||
|
# You can manually invoke the check via:
|
||||||
|
#
|
||||||
|
# lint_clean_files.sh
|
||||||
|
#
|
||||||
|
|
||||||
|
# root directories
|
||||||
|
#
|
||||||
|
aliases/
|
||||||
|
docs/
|
||||||
|
hooks/
|
||||||
|
scripts/
|
||||||
|
|
||||||
|
# root files
|
||||||
|
#
|
||||||
|
.gitattributes
|
||||||
|
bash_it.sh
|
||||||
|
clean_files.txt
|
||||||
|
install.sh
|
||||||
|
lint_clean_files.sh
|
||||||
|
|
||||||
|
# completions
|
||||||
|
#
|
||||||
|
completion/available/apm.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/cargo.completion.bash
|
||||||
|
completion/available/composer.completion.bash
|
||||||
|
completion/available/conda.completion.bash
|
||||||
|
completion/available/consul.completion.bash
|
||||||
|
completion/available/dart.completion.bash
|
||||||
|
completion/available/django.completion.bash
|
||||||
|
completion/available/dmidecode.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/gem.completion.bash
|
||||||
|
completion/available/git.completion.bash
|
||||||
|
completion/available/github-cli.completion.bash
|
||||||
|
completion/available/go.completion.bash
|
||||||
|
completion/available/helm.completion.bash
|
||||||
|
completion/available/jboss5.completion.bash
|
||||||
|
completion/available/jboss7.completion.bash
|
||||||
|
completion/available/jungle.completion.bash
|
||||||
|
completion/available/knife.completion.bash
|
||||||
|
completion/available/kontena.completion.bash
|
||||||
|
completion/available/kubectl.completion.bash
|
||||||
|
completion/available/laravel.completion.bash
|
||||||
|
completion/available/lerna.completion.bash
|
||||||
|
completion/available/minikube.completion.bash
|
||||||
|
completion/available/ngrok.completion.bash
|
||||||
|
completion/available/notify-send.completion.bash
|
||||||
|
completion/available/npm.completion.bash
|
||||||
|
completion/available/packer.completion.bash
|
||||||
|
completion/available/pip.completion.bash
|
||||||
|
completion/available/pip3.completion.bash
|
||||||
|
completion/available/pipenv.completion.bash
|
||||||
|
completion/available/pipx.completion.bash
|
||||||
|
completion/available/rustup.completion.bash
|
||||||
|
completion/available/sdkman.completion.bash
|
||||||
|
completion/available/system.completion.bash
|
||||||
|
completion/available/vault.completion.bash
|
||||||
|
completion/available/vuejs.completion.bash
|
||||||
|
completion/available/wpscan.completion.bash
|
||||||
|
completion/available/yarn.completion.bash
|
||||||
|
|
||||||
|
# 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
|
||||||
|
#
|
||||||
|
plugins/available/alias-completion.plugin.bash
|
||||||
|
plugins/available/autojump.plugin.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
|
||||||
|
#
|
||||||
|
test/completion/aliases.completion.bats
|
||||||
|
test/run
|
||||||
|
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/.gitattributes
|
||||||
|
|
@ -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,56 +1,4 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
|
about-completion "apm completion"
|
||||||
# apm-bash-completion is written by Ugur Ozyilmazel
|
# shellcheck disable=SC1090
|
||||||
# repo: https://github.com/vigo/apm-bash-completion
|
source "${BASH_IT}"/vendor/github.com/vigo/apm-bash-completion/apm
|
||||||
|
|
||||||
__apm(){
|
|
||||||
local cur prev options apm_command
|
|
||||||
COMPREPLY=()
|
|
||||||
cur="${COMP_WORDS[COMP_CWORD]}"
|
|
||||||
prev="${COMP_WORDS[COMP_CWORD-1]}"
|
|
||||||
__apm_get_command
|
|
||||||
if [[ $cur = -* ]]; then
|
|
||||||
options="--color"
|
|
||||||
if [[ -z $apm_command ]]; then
|
|
||||||
options="$options --version --help"
|
|
||||||
fi
|
|
||||||
if [[ $apm_command && $apm_command = publish ]]; then
|
|
||||||
options="--tag --rename"
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
if [[ -z $apm_command || $apm_command = help ]]; then
|
|
||||||
options="help clean config dedupe deinstall delete dev develop docs erase featured home init install link linked links list ln lns login ls open outdated publish rebuild rebuild-module-cache remove rm search show star starred stars test uninstall unlink unpublish unstar update upgrade view"
|
|
||||||
fi
|
|
||||||
if [[ $apm_command && $apm_command = publish ]]; then
|
|
||||||
options="major minor patch build"
|
|
||||||
fi
|
|
||||||
if [[ $apm_command && $apm_command = config ]]; then
|
|
||||||
options="set get delete list edit"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
COMPREPLY=($(compgen -W "$options" -- "$cur"))
|
|
||||||
}
|
|
||||||
__apm_get_command() {
|
|
||||||
local i
|
|
||||||
for ((i=1; i < $COMP_CWORD; ++i)); do
|
|
||||||
local arg=${COMP_WORDS[$i]}
|
|
||||||
case $arg in
|
|
||||||
[^-]*)
|
|
||||||
apm_command=$arg
|
|
||||||
return;;
|
|
||||||
--version)
|
|
||||||
apm_command=-
|
|
||||||
return;;
|
|
||||||
--help)
|
|
||||||
apm_command=help
|
|
||||||
return;;
|
|
||||||
publish)
|
|
||||||
apm_command=publish
|
|
||||||
return;;
|
|
||||||
config)
|
|
||||||
apm_command=config
|
|
||||||
return;;
|
|
||||||
esac
|
|
||||||
done
|
|
||||||
}
|
|
||||||
complete -F __apm -o bashdefault -o default apm
|
|
||||||
|
|
|
||||||
|
|
@ -1 +1,5 @@
|
||||||
[[ -x "$(which awless)" ]] && source <(awless completion bash)
|
# shellcheck shell=bash
|
||||||
|
if _command_exists awless; then
|
||||||
|
# shellcheck disable=SC1090
|
||||||
|
source <(awless completion bash)
|
||||||
|
fi
|
||||||
|
|
|
||||||
|
|
@ -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
|
||||||
|
|
|
||||||
|
|
@ -1,27 +1,30 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
|
cite "about-completion"
|
||||||
|
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
|
||||||
source "$BREW_PREFIX"/etc/bash_completion.d/brew
|
# shellcheck disable=1090,1091
|
||||||
|
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
|
||||||
source "$BREW_PREFIX"/Library/Contributions/brew_bash_completion.sh
|
# For the git-clone based installation, see here for more info:
|
||||||
|
# https://github.com/Bash-it/bash-it/issues/1458
|
||||||
elif [[ -f "$BREW_PREFIX"/completions/bash/brew ]] ; then
|
# https://docs.brew.sh/Shell-Completion
|
||||||
# For the git-clone based installation, see here for more info:
|
# shellcheck disable=1090,1091
|
||||||
# https://github.com/Bash-it/bash-it/issues/1458
|
source "$BASH_IT_HOMEBREW_PREFIX/completions/bash/brew"
|
||||||
# https://docs.brew.sh/Shell-Completion
|
|
||||||
source "$BREW_PREFIX"/completions/bash/brew
|
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,28 @@
|
||||||
#! bash
|
#! bash
|
||||||
# bash completion for the `bundle` command.
|
# bash completion for the `bundle` command.
|
||||||
#
|
#
|
||||||
# Copyright (c) 2011-2017 Daniel Luz <dev at mernen dot com>.
|
# Copyright (c) 2008 Daniel Luz
|
||||||
# Distributed under the MIT license.
|
|
||||||
# http://mernen.com/projects/completion-ruby
|
# 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.
|
||||||
#
|
#
|
||||||
# To use, source this file on bash:
|
# To use, source this file on bash:
|
||||||
# . completion-bundle
|
# . completion-bundle
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,6 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
# cargo (Rust package manager) completion
|
||||||
|
|
||||||
|
if _binary_exists rustup && _binary_exists cargo; then
|
||||||
|
eval "$(rustup completions bash cargo)"
|
||||||
|
fi
|
||||||
|
|
@ -1,133 +1,129 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
|
cite "about-completion"
|
||||||
|
about-completion "composer completion"
|
||||||
|
|
||||||
_composer()
|
function __composer_completion() {
|
||||||
{
|
local cur coms opts com words
|
||||||
local cur script coms opts com
|
COMPREPLY=()
|
||||||
COMPREPLY=()
|
_get_comp_words_by_ref -n : cur words
|
||||||
_get_comp_words_by_ref -n : cur words
|
|
||||||
|
|
||||||
# for an alias, get the real script behind it
|
# lookup for command
|
||||||
if [[ $(type -t ${words[0]}) == "alias" ]]; then
|
for word in "${words[@]:1}"; do
|
||||||
script=$(alias ${words[0]} | sed -E "s/alias ${words[0]}='(.*)'/\1/")
|
if [[ "${word}" != -* ]]; then
|
||||||
else
|
com="${word}"
|
||||||
script=${words[0]}
|
break
|
||||||
fi
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
# lookup for command
|
# completing for an option
|
||||||
for word in ${words[@]:1}; do
|
if [[ ${cur} == --* ]]; then
|
||||||
if [[ $word != -* ]]; then
|
opts="--help --quiet --verbose --version --ansi --no-ansi --no-interaction --profile --no-plugins --working-dir"
|
||||||
com=$word
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
# completing for an option
|
case "${com}" in
|
||||||
if [[ ${cur} == --* ]] ; then
|
about)
|
||||||
opts="--help --quiet --verbose --version --ansi --no-ansi --no-interaction --profile --no-plugins --working-dir"
|
opts="${opts} "
|
||||||
|
;;
|
||||||
|
archive)
|
||||||
|
opts="${opts} --format --dir --file"
|
||||||
|
;;
|
||||||
|
browse)
|
||||||
|
opts="${opts} --homepage --show"
|
||||||
|
;;
|
||||||
|
clear-cache)
|
||||||
|
opts="${opts} "
|
||||||
|
;;
|
||||||
|
config)
|
||||||
|
opts="${opts} --global --editor --auth --unset --list --file --absolute"
|
||||||
|
;;
|
||||||
|
create-project)
|
||||||
|
opts="${opts} --stability --prefer-source --prefer-dist --repository --repository-url --dev --no-dev --no-custom-installers --no-scripts --no-progress --no-secure-http --keep-vcs --no-install --ignore-platform-reqs"
|
||||||
|
;;
|
||||||
|
depends)
|
||||||
|
opts="${opts} --recursive --tree"
|
||||||
|
;;
|
||||||
|
diagnose)
|
||||||
|
opts="${opts} "
|
||||||
|
;;
|
||||||
|
dump-autoload)
|
||||||
|
opts="${opts} --no-scripts --optimize --classmap-authoritative --apcu --no-dev"
|
||||||
|
;;
|
||||||
|
exec)
|
||||||
|
opts="${opts} --list"
|
||||||
|
;;
|
||||||
|
global)
|
||||||
|
opts="${opts} "
|
||||||
|
;;
|
||||||
|
help)
|
||||||
|
opts="${opts} --xml --format --raw"
|
||||||
|
;;
|
||||||
|
init)
|
||||||
|
opts="${opts} --name --description --author --type --homepage --require --require-dev --stability --license --repository"
|
||||||
|
;;
|
||||||
|
install)
|
||||||
|
opts="${opts} --prefer-source --prefer-dist --dry-run --dev --no-dev --no-custom-installers --no-autoloader --no-scripts --no-progress --no-suggest --optimize-autoloader --classmap-authoritative --apcu-autoloader --ignore-platform-reqs"
|
||||||
|
;;
|
||||||
|
licenses)
|
||||||
|
opts="${opts} --format --no-dev"
|
||||||
|
;;
|
||||||
|
list)
|
||||||
|
opts="${opts} --xml --raw --format"
|
||||||
|
;;
|
||||||
|
outdated)
|
||||||
|
opts="${opts} --outdated --all --direct --strict"
|
||||||
|
;;
|
||||||
|
prohibits)
|
||||||
|
opts="${opts} --recursive --tree"
|
||||||
|
;;
|
||||||
|
remove)
|
||||||
|
opts="${opts} --dev --no-progress --no-update --no-scripts --update-no-dev --update-with-dependencies --no-update-with-dependencies --ignore-platform-reqs --optimize-autoloader --classmap-authoritative --apcu-autoloader"
|
||||||
|
;;
|
||||||
|
require)
|
||||||
|
opts="${opts} --dev --prefer-source --prefer-dist --no-progress --no-suggest --no-update --no-scripts --update-no-dev --update-with-dependencies --ignore-platform-reqs --prefer-stable --prefer-lowest --sort-packages --optimize-autoloader --classmap-authoritative --apcu-autoloader"
|
||||||
|
;;
|
||||||
|
run-script)
|
||||||
|
opts="${opts} --timeout --dev --no-dev --list"
|
||||||
|
;;
|
||||||
|
search)
|
||||||
|
opts="${opts} --only-name --type"
|
||||||
|
;;
|
||||||
|
self-update)
|
||||||
|
opts="${opts} --rollback --clean-backups --no-progress --update-keys --stable --preview --snapshot"
|
||||||
|
;;
|
||||||
|
show)
|
||||||
|
opts="${opts} --all --installed --platform --available --self --name-only --path --tree --latest --outdated --minor-only --direct --strict"
|
||||||
|
;;
|
||||||
|
status)
|
||||||
|
opts="${opts} "
|
||||||
|
;;
|
||||||
|
suggests)
|
||||||
|
opts="${opts} --by-package --by-suggestion --no-dev"
|
||||||
|
;;
|
||||||
|
update)
|
||||||
|
opts="${opts} --prefer-source --prefer-dist --dry-run --dev --no-dev --lock --no-custom-installers --no-autoloader --no-scripts --no-progress --no-suggest --with-dependencies --optimize-autoloader --classmap-authoritative --apcu-autoloader --ignore-platform-reqs --prefer-stable --prefer-lowest --interactive --root-reqs"
|
||||||
|
;;
|
||||||
|
validate)
|
||||||
|
opts="${opts} --no-check-all --no-check-lock --no-check-publish --with-dependencies --strict"
|
||||||
|
;;
|
||||||
|
|
||||||
case "$com" in
|
esac
|
||||||
about)
|
|
||||||
opts="${opts} "
|
|
||||||
;;
|
|
||||||
archive)
|
|
||||||
opts="${opts} --format --dir --file"
|
|
||||||
;;
|
|
||||||
browse)
|
|
||||||
opts="${opts} --homepage --show"
|
|
||||||
;;
|
|
||||||
clear-cache)
|
|
||||||
opts="${opts} "
|
|
||||||
;;
|
|
||||||
config)
|
|
||||||
opts="${opts} --global --editor --auth --unset --list --file --absolute"
|
|
||||||
;;
|
|
||||||
create-project)
|
|
||||||
opts="${opts} --stability --prefer-source --prefer-dist --repository --repository-url --dev --no-dev --no-custom-installers --no-scripts --no-progress --no-secure-http --keep-vcs --no-install --ignore-platform-reqs"
|
|
||||||
;;
|
|
||||||
depends)
|
|
||||||
opts="${opts} --recursive --tree"
|
|
||||||
;;
|
|
||||||
diagnose)
|
|
||||||
opts="${opts} "
|
|
||||||
;;
|
|
||||||
dump-autoload)
|
|
||||||
opts="${opts} --no-scripts --optimize --classmap-authoritative --apcu --no-dev"
|
|
||||||
;;
|
|
||||||
exec)
|
|
||||||
opts="${opts} --list"
|
|
||||||
;;
|
|
||||||
global)
|
|
||||||
opts="${opts} "
|
|
||||||
;;
|
|
||||||
help)
|
|
||||||
opts="${opts} --xml --format --raw"
|
|
||||||
;;
|
|
||||||
init)
|
|
||||||
opts="${opts} --name --description --author --type --homepage --require --require-dev --stability --license --repository"
|
|
||||||
;;
|
|
||||||
install)
|
|
||||||
opts="${opts} --prefer-source --prefer-dist --dry-run --dev --no-dev --no-custom-installers --no-autoloader --no-scripts --no-progress --no-suggest --optimize-autoloader --classmap-authoritative --apcu-autoloader --ignore-platform-reqs"
|
|
||||||
;;
|
|
||||||
licenses)
|
|
||||||
opts="${opts} --format --no-dev"
|
|
||||||
;;
|
|
||||||
list)
|
|
||||||
opts="${opts} --xml --raw --format"
|
|
||||||
;;
|
|
||||||
outdated)
|
|
||||||
opts="${opts} --outdated --all --direct --strict"
|
|
||||||
;;
|
|
||||||
prohibits)
|
|
||||||
opts="${opts} --recursive --tree"
|
|
||||||
;;
|
|
||||||
remove)
|
|
||||||
opts="${opts} --dev --no-progress --no-update --no-scripts --update-no-dev --update-with-dependencies --no-update-with-dependencies --ignore-platform-reqs --optimize-autoloader --classmap-authoritative --apcu-autoloader"
|
|
||||||
;;
|
|
||||||
require)
|
|
||||||
opts="${opts} --dev --prefer-source --prefer-dist --no-progress --no-suggest --no-update --no-scripts --update-no-dev --update-with-dependencies --ignore-platform-reqs --prefer-stable --prefer-lowest --sort-packages --optimize-autoloader --classmap-authoritative --apcu-autoloader"
|
|
||||||
;;
|
|
||||||
run-script)
|
|
||||||
opts="${opts} --timeout --dev --no-dev --list"
|
|
||||||
;;
|
|
||||||
search)
|
|
||||||
opts="${opts} --only-name --type"
|
|
||||||
;;
|
|
||||||
self-update)
|
|
||||||
opts="${opts} --rollback --clean-backups --no-progress --update-keys --stable --preview --snapshot"
|
|
||||||
;;
|
|
||||||
show)
|
|
||||||
opts="${opts} --all --installed --platform --available --self --name-only --path --tree --latest --outdated --minor-only --direct --strict"
|
|
||||||
;;
|
|
||||||
status)
|
|
||||||
opts="${opts} "
|
|
||||||
;;
|
|
||||||
suggests)
|
|
||||||
opts="${opts} --by-package --by-suggestion --no-dev"
|
|
||||||
;;
|
|
||||||
update)
|
|
||||||
opts="${opts} --prefer-source --prefer-dist --dry-run --dev --no-dev --lock --no-custom-installers --no-autoloader --no-scripts --no-progress --no-suggest --with-dependencies --optimize-autoloader --classmap-authoritative --apcu-autoloader --ignore-platform-reqs --prefer-stable --prefer-lowest --interactive --root-reqs"
|
|
||||||
;;
|
|
||||||
validate)
|
|
||||||
opts="${opts} --no-check-all --no-check-lock --no-check-publish --with-dependencies --strict"
|
|
||||||
;;
|
|
||||||
|
|
||||||
esac
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "${opts}" -- "${cur}"))
|
||||||
|
__ltrim_colon_completions "${cur}"
|
||||||
|
|
||||||
COMPREPLY=($(compgen -W "${opts}" -- ${cur}))
|
return 0
|
||||||
__ltrim_colon_completions "$cur"
|
fi
|
||||||
|
|
||||||
return 0;
|
# completing for a command
|
||||||
fi
|
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"
|
||||||
|
|
||||||
# completing for a command
|
# shellcheck disable=SC2207
|
||||||
if [[ $cur == $com ]]; then
|
COMPREPLY=($(compgen -W "${coms}" -- "${cur}"))
|
||||||
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"
|
__ltrim_colon_completions "${cur}"
|
||||||
|
|
||||||
COMPREPLY=($(compgen -W "${coms}" -- ${cur}))
|
return 0
|
||||||
__ltrim_colon_completions "$cur"
|
fi
|
||||||
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
complete -o default -F _composer composer
|
complete -o default -F __composer_completion composer
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,11 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
which register-python-argcomplete > /dev/null \
|
cite "about-completion"
|
||||||
&& eval "$(register-python-argcomplete conda)" \
|
about-completion "conda completion"
|
||||||
|| echo "Please install argcomplete to use conda completion"
|
|
||||||
|
if _command_exists conda; then
|
||||||
|
if _command_exists register-python-argcomplete; then
|
||||||
|
eval "$(register-python-argcomplete conda)"
|
||||||
|
else
|
||||||
|
_log_warning "Argcomplete not found. Please run 'conda install argcomplete'"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,7 @@
|
||||||
# bash completion support for Hashicorp consul
|
# shellcheck shell=bash
|
||||||
|
cite "about-completion"
|
||||||
|
about-completion "Hashicorp consul completion"
|
||||||
|
|
||||||
CONSUL_BIN=$(command -v consul 2>/dev/null)
|
if _command_exists consul; then
|
||||||
|
complete -C "$(command -v consul)" consul
|
||||||
if [[ -x "$CONSUL_BIN" ]]
|
|
||||||
then
|
|
||||||
complete -C "$CONSUL_BIN" consul
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
unset CONSUL_BIN
|
|
||||||
|
|
@ -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.
|
|
||||||
|
|
|
||||||
|
|
@ -1,72 +1,4 @@
|
||||||
# #########################################################################
|
# shellcheck shell=bash
|
||||||
# This bash script adds tab-completion feature to django-admin.py and
|
about-completion "django completion"
|
||||||
# manage.py.
|
# shellcheck disable=SC1090
|
||||||
#
|
source "${BASH_IT}"/vendor/github.com/django/django/extras/django_bash_completion
|
||||||
# Testing it out without installing
|
|
||||||
# =================================
|
|
||||||
#
|
|
||||||
# To test out the completion without "installing" this, just run this file
|
|
||||||
# directly, like so:
|
|
||||||
#
|
|
||||||
# . ~/path/to/django_bash_completion
|
|
||||||
#
|
|
||||||
# Note: There's a dot ('.') at the beginning of that command.
|
|
||||||
#
|
|
||||||
# After you do that, tab completion will immediately be made available in your
|
|
||||||
# current Bash shell. But it won't be available next time you log in.
|
|
||||||
#
|
|
||||||
# Installing
|
|
||||||
# ==========
|
|
||||||
#
|
|
||||||
# To install this, point to this file from your .bash_profile, like so:
|
|
||||||
#
|
|
||||||
# . ~/path/to/django_bash_completion
|
|
||||||
#
|
|
||||||
# Do the same in your .bashrc if .bashrc doesn't invoke .bash_profile.
|
|
||||||
#
|
|
||||||
# Settings will take effect the next time you log in.
|
|
||||||
#
|
|
||||||
# Uninstalling
|
|
||||||
# ============
|
|
||||||
#
|
|
||||||
# To uninstall, just remove the line from your .bash_profile and .bashrc.
|
|
||||||
|
|
||||||
_django_completion()
|
|
||||||
{
|
|
||||||
COMPREPLY=( $( COMP_WORDS="${COMP_WORDS[*]}" \
|
|
||||||
COMP_CWORD=$COMP_CWORD \
|
|
||||||
DJANGO_AUTO_COMPLETE=1 $1 ) )
|
|
||||||
}
|
|
||||||
complete -F _django_completion -o default django-admin.py manage.py django-admin
|
|
||||||
|
|
||||||
_python_django_completion()
|
|
||||||
{
|
|
||||||
if [[ ${COMP_CWORD} -ge 2 ]]; then
|
|
||||||
PYTHON_EXE=$( basename -- ${COMP_WORDS[0]} )
|
|
||||||
echo $PYTHON_EXE | egrep "python([2-9]\.[0-9])?" >/dev/null 2>&1
|
|
||||||
if [[ $? == 0 ]]; then
|
|
||||||
PYTHON_SCRIPT=$( basename -- ${COMP_WORDS[1]} )
|
|
||||||
echo $PYTHON_SCRIPT | egrep "manage\.py|django-admin(\.py)?" >/dev/null 2>&1
|
|
||||||
if [[ $? == 0 ]]; then
|
|
||||||
COMPREPLY=( $( COMP_WORDS="${COMP_WORDS[*]:1}" \
|
|
||||||
COMP_CWORD=$(( COMP_CWORD-1 )) \
|
|
||||||
DJANGO_AUTO_COMPLETE=1 ${COMP_WORDS[*]} ) )
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# Support for multiple interpreters.
|
|
||||||
unset pythons
|
|
||||||
if command -v whereis &>/dev/null; then
|
|
||||||
python_interpreters=$(whereis python | cut -d " " -f 2-)
|
|
||||||
for python in $python_interpreters; do
|
|
||||||
pythons="${pythons} $(basename -- $python)"
|
|
||||||
done
|
|
||||||
pythons=$(echo $pythons | tr " " "\n" | sort -u | tr "\n" " ")
|
|
||||||
else
|
|
||||||
pythons=python
|
|
||||||
fi
|
|
||||||
|
|
||||||
complete -F _python_django_completion -o default $pythons
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -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
|
||||||
|
|
@ -1,5 +1,20 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
#
|
#
|
||||||
|
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
# you may not use this file except in compliance with the License.
|
||||||
|
# You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
# See the License for the specific language governing permissions and
|
||||||
|
# limitations under the License.
|
||||||
|
|
||||||
|
# Copyright (c) 2014 Docker, Inc
|
||||||
|
|
||||||
# bash completion for docker-compose
|
# bash completion for docker-compose
|
||||||
#
|
#
|
||||||
# This work is based on the completion for the docker command.
|
# This work is based on the completion for the docker command.
|
||||||
|
|
@ -661,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
|
||||||
|
|
@ -670,4 +685,4 @@ _docker_compose() {
|
||||||
eval "$__docker_compose_previous_extglob_setting"
|
eval "$__docker_compose_previous_extglob_setting"
|
||||||
unset __docker_compose_previous_extglob_setting
|
unset __docker_compose_previous_extglob_setting
|
||||||
|
|
||||||
complete -F _docker_compose docker-compose docker-compose.exe
|
complete -F _docker_compose docker-compose docker-compose.exe
|
||||||
|
|
|
||||||
|
|
@ -1,416 +1,3 @@
|
||||||
#
|
# shellcheck shell=bash
|
||||||
# bash completion file for docker-machine commands
|
_log_warning '"docker-machine" is now deprecated, and as such the bash completion for it is also deprecated.
|
||||||
#
|
Please disable this completion.'
|
||||||
# This script provides completion of:
|
|
||||||
# - commands and their options
|
|
||||||
# - machine names
|
|
||||||
# - filepaths
|
|
||||||
#
|
|
||||||
# To enable the completions either:
|
|
||||||
# - place this file in /etc/bash_completion.d
|
|
||||||
# or
|
|
||||||
# - copy this file to e.g. ~/.docker-machine-completion.sh and add the line
|
|
||||||
# below to your .bashrc after bash completion features are loaded
|
|
||||||
# . ~/.docker-machine-completion.sh
|
|
||||||
#
|
|
||||||
|
|
||||||
# --- helper functions -------------------------------------------------------
|
|
||||||
|
|
||||||
_docker_machine_q() {
|
|
||||||
docker-machine 2>/dev/null "$@"
|
|
||||||
}
|
|
||||||
|
|
||||||
# suppresses trailing whitespace
|
|
||||||
_docker_machine_nospace() {
|
|
||||||
# compopt is not available in ancient bash versions (OSX)
|
|
||||||
# so only call it if it's available
|
|
||||||
type compopt &>/dev/null && compopt -o nospace
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_machines() {
|
|
||||||
_docker_machine_q ls --format '{{.Name}}' "$@"
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_drivers() {
|
|
||||||
local drivers=(
|
|
||||||
amazonec2
|
|
||||||
azure
|
|
||||||
digitalocean
|
|
||||||
exoscale
|
|
||||||
generic
|
|
||||||
google
|
|
||||||
hyperv
|
|
||||||
openstack
|
|
||||||
rackspace
|
|
||||||
softlayer
|
|
||||||
virtualbox
|
|
||||||
vmwarefusion
|
|
||||||
vmwarevcloudair
|
|
||||||
vmwarevsphere
|
|
||||||
)
|
|
||||||
echo "${drivers[@]}"
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_value_of_option() {
|
|
||||||
local pattern="$1"
|
|
||||||
for (( i=2; i < ${cword}; ++i)); do
|
|
||||||
if [[ ${words[$i]} =~ ^($pattern)$ ]] ; then
|
|
||||||
echo ${words[$i + 1]}
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
# Returns `key` if we are currently completing the value of a map option
|
|
||||||
# (`key=value`) which matches the glob passed in as an argument.
|
|
||||||
# This function is needed for key-specific argument completions.
|
|
||||||
_docker_machine_map_key_of_current_option() {
|
|
||||||
local glob="$1"
|
|
||||||
|
|
||||||
local key glob_pos
|
|
||||||
if [ "$cur" = "=" ] ; then # key= case
|
|
||||||
key="$prev"
|
|
||||||
glob_pos=$((cword - 2))
|
|
||||||
elif [[ $cur == *=* ]] ; then # key=value case (OSX)
|
|
||||||
key=${cur%=*}
|
|
||||||
glob_pos=$((cword - 1))
|
|
||||||
elif [ "$prev" = "=" ] ; then
|
|
||||||
key=${words[$cword - 2]} # key=value case
|
|
||||||
glob_pos=$((cword - 3))
|
|
||||||
else
|
|
||||||
return
|
|
||||||
fi
|
|
||||||
|
|
||||||
[ "${words[$glob_pos]}" = "=" ] && ((glob_pos--)) # --option=key=value syntax
|
|
||||||
|
|
||||||
[[ ${words[$glob_pos]} == $glob ]] && echo "$key"
|
|
||||||
}
|
|
||||||
|
|
||||||
# Finds the position of the first word that is neither option nor an option's argument.
|
|
||||||
# If there are options that require arguments, you need to pass a glob describing
|
|
||||||
# those options, e.g. "--option1|-o|--option2".
|
|
||||||
# Use this function to restrict completions to exact positions after the options.
|
|
||||||
_docker_machine_pos_first_nonflag() {
|
|
||||||
local argument_flags=$1
|
|
||||||
|
|
||||||
local counter=$((${subcommand_pos:-${command_pos}} + 1))
|
|
||||||
while [ "$counter" -le "$cword" ]; do
|
|
||||||
if [ -n "$argument_flags" ] && eval "case '${words[$counter]}' in $argument_flags) true ;; *) false ;; esac"; then
|
|
||||||
(( counter++ ))
|
|
||||||
# eat "=" in case of --option=arg syntax
|
|
||||||
[ "${words[$counter]}" = "=" ] && (( counter++ ))
|
|
||||||
else
|
|
||||||
case "${words[$counter]}" in
|
|
||||||
-*)
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
break
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Bash splits words at "=", retaining "=" as a word, examples:
|
|
||||||
# "--debug=false" => 3 words, "--log-opt syslog-facility=daemon" => 4 words
|
|
||||||
while [ "${words[$counter + 1]}" = "=" ] ; do
|
|
||||||
counter=$(( counter + 2))
|
|
||||||
done
|
|
||||||
|
|
||||||
(( counter++ ))
|
|
||||||
done
|
|
||||||
|
|
||||||
echo $counter
|
|
||||||
}
|
|
||||||
# --- completion functions ---------------------------------------------------
|
|
||||||
|
|
||||||
_docker_machine_active() {
|
|
||||||
case "${prev}" in
|
|
||||||
--timeout|-t)
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help --timeout -t" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_config() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help --swarm" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_create() {
|
|
||||||
case "${prev}" in
|
|
||||||
--driver|-d)
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_drivers)" -- "${cur}"))
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
# driver specific options are only included in help output if --driver is given,
|
|
||||||
# so we have to pass that option when calling docker-machine to harvest options.
|
|
||||||
local driver="$(_docker_machine_value_of_option '--driver|-d')"
|
|
||||||
local parsed_options="$(_docker_machine_q create ${driver:+--driver $driver} --help | grep '^ -' | sed 's/^ //; s/[^a-z0-9-].*$//')"
|
|
||||||
if [[ ${cur} == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "${parsed_options} -d --help" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_env() {
|
|
||||||
case "${prev}" in
|
|
||||||
--shell)
|
|
||||||
COMPREPLY=($(compgen -W "cmd emacs fish powershell tcsh" -- "${cur}"))
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help --no-proxy --shell --swarm --unset -u" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# See docker-machine-wrapper.bash for the use command
|
|
||||||
_docker_machine_use() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help --swarm --unset" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_inspect() {
|
|
||||||
case "${prev}" in
|
|
||||||
--format|-f)
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--format -f --help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_ip() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_kill() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_ls() {
|
|
||||||
local key=$(_docker_machine_map_key_of_current_option '--filter')
|
|
||||||
case "$key" in
|
|
||||||
driver)
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_drivers)" -- "${cur##*=}"))
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
state)
|
|
||||||
COMPREPLY=($(compgen -W "Error Paused Running Saved Starting Stopped Stopping" -- "${cur##*=}"))
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
case "${prev}" in
|
|
||||||
--filter)
|
|
||||||
COMPREPLY=($(compgen -W "driver label name state swarm" -S= -- "${cur}"))
|
|
||||||
_docker_machine_nospace
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
--format|-f|--timeout|-t)
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--filter --format -f --help --quiet -q --timeout -t" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_mount() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help --unmount -u" -- "${cur}"))
|
|
||||||
else
|
|
||||||
local pos=$(_docker_machine_pos_first_nonflag)
|
|
||||||
if [ "$cword" -eq "$pos" ]; then
|
|
||||||
# We can't complete remote filesystems. All we can do here is to complete the machine.
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines --filter state=Running)" -S: -- "${cur}"))
|
|
||||||
_docker_machine_nospace
|
|
||||||
elif [ "$cword" -eq "$((pos + 1))" ]; then
|
|
||||||
_filedir -d
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_provision() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines --filter state=Running)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_regenerate_certs() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--client-certs --force -f --help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines --filter state=Running)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_restart() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_rm() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--force -f --help -y" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_ssh() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_scp() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--delta -d --help --quiet -q --recursive -r" -- "${cur}"))
|
|
||||||
else
|
|
||||||
_filedir
|
|
||||||
# It would be really nice to ssh to the machine and ls to complete
|
|
||||||
# remote files.
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines | sed 's/$/:/')" -- "${cur}") "${COMPREPLY[@]}")
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_start() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines --filter state=Stopped)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_status() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_stop() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines --filter state=Running)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_upgrade() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_url() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_version() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "$(_docker_machine_machines)" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_help() {
|
|
||||||
if [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "--help" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "${commands[*]}" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine_docker_machine() {
|
|
||||||
if [[ " ${wants_file[*]} " =~ " ${prev} " ]]; then
|
|
||||||
_filedir
|
|
||||||
elif [[ " ${wants_dir[*]} " =~ " ${prev} " ]]; then
|
|
||||||
_filedir -d
|
|
||||||
elif [[ "${cur}" == -* ]]; then
|
|
||||||
COMPREPLY=($(compgen -W "${flags[*]} ${wants_dir[*]} ${wants_file[*]}" -- "${cur}"))
|
|
||||||
else
|
|
||||||
COMPREPLY=($(compgen -W "${commands[*]}" -- "${cur}"))
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
_docker_machine() {
|
|
||||||
COMPREPLY=()
|
|
||||||
local commands=(active config create env inspect ip kill ls mount provision regenerate-certs restart rm ssh scp start status stop upgrade url version help)
|
|
||||||
|
|
||||||
local flags=(--debug --native-ssh --github-api-token --bugsnag-api-token --help --version)
|
|
||||||
local wants_dir=(--storage-path)
|
|
||||||
local wants_file=(--tls-ca-cert --tls-ca-key --tls-client-cert --tls-client-key)
|
|
||||||
|
|
||||||
# Add the use subcommand, if we have an alias loaded
|
|
||||||
if [[ ${DOCKER_MACHINE_WRAPPED} = true ]]; then
|
|
||||||
commands=("${commands[@]}" use)
|
|
||||||
fi
|
|
||||||
|
|
||||||
local cur prev words cword
|
|
||||||
_get_comp_words_by_ref -n : cur prev words cword
|
|
||||||
local i
|
|
||||||
local command=docker-machine command_pos=0
|
|
||||||
|
|
||||||
for (( i=1; i < ${cword}; ++i)); do
|
|
||||||
local word=${words[i]}
|
|
||||||
if [[ " ${wants_file[*]} ${wants_dir[*]} " =~ " ${word} " ]]; then
|
|
||||||
# skip the next option
|
|
||||||
(( ++i ))
|
|
||||||
elif [[ " ${commands[*]} " =~ " ${word} " ]]; then
|
|
||||||
command=${word}
|
|
||||||
command_pos=$i
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
local completion_func=_docker_machine_"${command//-/_}"
|
|
||||||
if declare -F "${completion_func}" > /dev/null; then
|
|
||||||
${completion_func}
|
|
||||||
fi
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
complete -F _docker_machine docker-machine docker-machine.exe
|
|
||||||
|
|
|
||||||
|
|
@ -1,21 +1,24 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
|
cite "about-completion"
|
||||||
|
about-completion "docker completion"
|
||||||
|
|
||||||
# Make sure docker is installed
|
# Make sure docker is installed
|
||||||
_command_exists docker || return
|
_command_exists docker || return
|
||||||
|
|
||||||
# Don't handle completion if it's already managed
|
# Don't handle completion if it's already managed
|
||||||
complete -p docker &>/dev/null && return
|
_completion_exists docker && return
|
||||||
|
|
||||||
_docker_bash_completion_paths=(
|
_docker_bash_completion_paths=(
|
||||||
# MacOS
|
# MacOS
|
||||||
'/Applications/Docker.app/Contents/Resources/etc/docker.bash-completion'
|
'/Applications/Docker.app/Contents/Resources/etc/docker.bash-completion'
|
||||||
# Linux
|
# Linux
|
||||||
'/usr/share/bash-completion/completions/docker'
|
'/usr/share/bash-completion/completions/docker'
|
||||||
)
|
)
|
||||||
|
|
||||||
for fn in "${_docker_bash_completion_paths[@]}" ; do
|
for fn in "${_docker_bash_completion_paths[@]}"; do
|
||||||
if [ -r "$fn" ] ; then
|
if [ -r "$fn" ]; then
|
||||||
source "$fn"
|
# shellcheck disable=SC1090
|
||||||
break
|
source "$fn"
|
||||||
fi
|
break
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
|
|
|
||||||
|
|
@ -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,37 +1,2 @@
|
||||||
#!/usr/bin/env bash
|
_log_warning 'Bash completion for "drush" is now deprecated, as it used code with incompatible license.
|
||||||
#
|
Please disable this completion and use the instructions from "drush" developers instead.'
|
||||||
# bash completion support for Drush:
|
|
||||||
# https://github.com/drush-ops/drush
|
|
||||||
#
|
|
||||||
# Originally from:
|
|
||||||
# http://github.com/drush-ops/drush/blob/master/drush.complete.sh
|
|
||||||
|
|
||||||
# Ensure drush is available.
|
|
||||||
which drush &> /dev/null || alias drush &> /dev/null || return
|
|
||||||
|
|
||||||
__drush_ps1() {
|
|
||||||
f="${TMPDIR:-/tmp/}/drush-env/drush-drupal-site-$$"
|
|
||||||
if [ -f $f ]
|
|
||||||
then
|
|
||||||
__DRUPAL_SITE=$(cat "$f")
|
|
||||||
else
|
|
||||||
__DRUPAL_SITE="$DRUPAL_SITE"
|
|
||||||
fi
|
|
||||||
|
|
||||||
[[ -n "$__DRUPAL_SITE" ]] && printf "${1:- (%s)}" "$__DRUPAL_SITE"
|
|
||||||
}
|
|
||||||
|
|
||||||
# Completion function, uses the "drush complete" command to retrieve
|
|
||||||
# completions for a specific command line COMP_WORDS.
|
|
||||||
_drush_completion() {
|
|
||||||
# Set IFS to newline (locally), since we only use newline separators, and
|
|
||||||
# need to retain spaces (or not) after completions.
|
|
||||||
local IFS=$'\n'
|
|
||||||
# The '< /dev/null' is a work around for a bug in php libedit stdin handling.
|
|
||||||
# Note that libedit in place of libreadline in some distributions. See:
|
|
||||||
# https://bugs.launchpad.net/ubuntu/+source/php5/+bug/322214
|
|
||||||
COMPREPLY=( $(drush --early=includes/complete.inc "${COMP_WORDS[@]}" < /dev/null 2> /dev/null) )
|
|
||||||
}
|
|
||||||
|
|
||||||
# Register our completion function. We include common short aliases for Drush.
|
|
||||||
complete -o bashdefault -o default -o nospace -F _drush_completion d dr drush drush5 drush6 drush6 drush.php
|
|
||||||
|
|
|
||||||
|
|
@ -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,9 +1,14 @@
|
||||||
#/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
# Bash completion for Google Cloud SDK
|
cite "about-completion"
|
||||||
|
about-completion "Google Cloud SDK completion"
|
||||||
|
|
||||||
if which gcloud >/dev/null 2>&1; then
|
if _command_exists gcloud; then
|
||||||
GOOGLE_SDK_ROOT=${GOOGLE_SDK_ROOT:-$(gcloud info --format="value(installation.sdk_root)")}
|
# get install path
|
||||||
for i in $(ls ${GOOGLE_SDK_ROOT}/*.bash.inc); do
|
GOOGLE_SDK_ROOT=${GOOGLE_SDK_ROOT:-$(gcloud info --format="value(installation.sdk_root)")}
|
||||||
source $i
|
|
||||||
done
|
# source all the bash completion file that are available
|
||||||
|
for i in "${GOOGLE_SDK_ROOT}"/*.bash.inc; do
|
||||||
|
# shellcheck disable=SC1090
|
||||||
|
source "$i"
|
||||||
|
done
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,41 +1,35 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
# Completion for gem
|
cite "about-completion"
|
||||||
|
about-completion "gem completion"
|
||||||
|
|
||||||
_installcomp() {
|
__gem_completion() {
|
||||||
if [ -z "$REMOTE_GEMS" ]
|
local cur=${COMP_WORDS[COMP_CWORD]}
|
||||||
then
|
local prev=${COMP_WORDS[COMP_CWORD - 1]}
|
||||||
REMOTE_GEMS=( $(gem list --remote --no-versions | tr '\n' ' ') )
|
case $prev in
|
||||||
fi
|
install)
|
||||||
|
# list the remote gems and add to completion
|
||||||
local cur=${COMP_WORDS[COMP_CWORD]}
|
if [ -z "$REMOTE_GEMS" ]; then
|
||||||
COMPREPLY=( $(compgen -W "${REMOTE_GEMS[*]}" -- $cur) )
|
read -r -a REMOTE_GEMS <<< "$(gem list --remote --no-versions | sed 's/\*\*\* REMOTE GEMS \*\*\*//' | tr '\n' ' ')"
|
||||||
|
fi
|
||||||
|
|
||||||
|
local cur=${COMP_WORDS[COMP_CWORD]}
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "${REMOTE_GEMS[*]}" -- "$cur"))
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
uninstall)
|
||||||
|
# list all local installed gems and add to completion
|
||||||
|
read -r -a LOCAL_GEMS <<< "$(gem list --no-versions | sed 's/\*\*\* LOCAL GEMS \*\*\*//' | tr '\n' ' ')"
|
||||||
|
|
||||||
|
local cur=${COMP_WORDS[COMP_CWORD]}
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "${LOCAL_GEMS[*]}" -- "$cur"))
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
local commands=(build cert check cleanup contents dependency environment fetch generate_index help install list lock outdated owner pristine push query rdoc search server sources specification stale uninstall unpack update which)
|
||||||
|
# shellcheck disable=SC2207
|
||||||
|
COMPREPLY=($(compgen -W "${commands[*]}" -- "$cur"))
|
||||||
}
|
}
|
||||||
|
|
||||||
_uninstallcomp() {
|
complete -F __gem_completion gem
|
||||||
if [ -z "$LOCAL_GEMS" ]
|
|
||||||
then
|
|
||||||
LOCAL_GEMS=( $(gem list --no-versions | sed 's/\*\*\* LOCAL GEMS \*\*\*//' | tr '\n' ' ') )
|
|
||||||
fi
|
|
||||||
|
|
||||||
local cur=${COMP_WORDS[COMP_CWORD]}
|
|
||||||
COMPREPLY=( $(compgen -W "${LOCAL_GEMS[*]}" -- $cur) )
|
|
||||||
}
|
|
||||||
|
|
||||||
_gem() {
|
|
||||||
local cur=${COMP_WORDS[COMP_CWORD]}
|
|
||||||
local prev=${COMP_WORDS[COMP_CWORD-1]}
|
|
||||||
case $prev in
|
|
||||||
install)
|
|
||||||
_installcomp
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
uninstall)
|
|
||||||
_uninstallcomp
|
|
||||||
return 0
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
local commands=(build cert check cleanup contents dependency environment fetch generate_index help install list lock outdated owner pristine push query rdoc search server sources specification stale uninstall unpack update which)
|
|
||||||
COMPREPLY=( $(compgen -W "${commands[*]}" -- $cur) )
|
|
||||||
}
|
|
||||||
|
|
||||||
complete -F _gem gem
|
|
||||||
|
|
|
||||||
|
|
@ -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
|
|
||||||
|
|
|
||||||
|
|
@ -2,47 +2,47 @@
|
||||||
#
|
#
|
||||||
# git-flow-completion
|
# git-flow-completion
|
||||||
# ===================
|
# ===================
|
||||||
#
|
#
|
||||||
# Bash completion support for [git-flow](http://github.com/nvie/gitflow)
|
# Bash completion support for [git-flow](http://github.com/nvie/gitflow)
|
||||||
#
|
#
|
||||||
# The contained completion routines provide support for completing:
|
# The contained completion routines provide support for completing:
|
||||||
#
|
#
|
||||||
# * git-flow init and version
|
# * git-flow init and version
|
||||||
# * feature, hotfix and release branches
|
# * feature, hotfix and release branches
|
||||||
# * remote feature branch names (for `git-flow feature track`)
|
# * remote feature branch names (for `git-flow feature track`)
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
# Installation
|
# Installation
|
||||||
# ------------
|
# ------------
|
||||||
#
|
#
|
||||||
# To achieve git-flow completion nirvana:
|
# To achieve git-flow completion nirvana:
|
||||||
#
|
#
|
||||||
# 0. Install git-completion.
|
# 0. Install git-completion.
|
||||||
#
|
#
|
||||||
# 1. Install this file. Either:
|
# 1. Install this file. Either:
|
||||||
#
|
#
|
||||||
# a. Place it in a `bash-completion.d` folder:
|
# a. Place it in a `bash-completion.d` folder:
|
||||||
#
|
#
|
||||||
# * /etc/bash-completion.d
|
# * /etc/bash-completion.d
|
||||||
# * /usr/local/etc/bash-completion.d
|
# * /usr/local/etc/bash-completion.d
|
||||||
# * ~/bash-completion.d
|
# * ~/bash-completion.d
|
||||||
#
|
#
|
||||||
# b. Or, copy it somewhere (e.g. ~/.git-flow-completion.sh) and put the following line in
|
# b. Or, copy it somewhere (e.g. ~/.git-flow-completion.sh) and put the following line in
|
||||||
# your .bashrc:
|
# your .bashrc:
|
||||||
#
|
#
|
||||||
# source ~/.git-flow-completion.sh
|
# source ~/.git-flow-completion.sh
|
||||||
#
|
#
|
||||||
# 2. If you are using Git < 1.7.1: Edit git-completion.sh and add the following line to the giant
|
# 2. If you are using Git < 1.7.1: Edit git-completion.sh and add the following line to the giant
|
||||||
# $command case in _git:
|
# $command case in _git:
|
||||||
#
|
#
|
||||||
# flow) _git_flow ;;
|
# flow) _git_flow ;;
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
# The Fine Print
|
# The Fine Print
|
||||||
# --------------
|
# --------------
|
||||||
#
|
#
|
||||||
# Copyright (c) 2010 [Justin Hileman](http://justinhileman.com)
|
# Copyright (c) 2010 [Justin Hileman](http://justinhileman.com)
|
||||||
#
|
#
|
||||||
# Distributed under the [MIT License](http://creativecommons.org/licenses/MIT/)
|
# Distributed under the [MIT License](http://creativecommons.org/licenses/MIT/)
|
||||||
|
|
||||||
_git_flow ()
|
_git_flow ()
|
||||||
|
|
@ -128,7 +128,7 @@ __git_flow_release ()
|
||||||
__gitcomp "$subcommands"
|
__gitcomp "$subcommands"
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
case "$subcommand" in
|
case "$subcommand" in
|
||||||
finish)
|
finish)
|
||||||
__gitcomp "$(__git_flow_list_releases)"
|
__gitcomp "$(__git_flow_list_releases)"
|
||||||
|
|
@ -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,10 +1,9 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
cite "about-completion"
|
cite "about-completion"
|
||||||
about-completion "GitHub CLI completion"
|
about-completion "GitHub CLI completion"
|
||||||
|
|
||||||
if _binary_exists gh; then
|
if _binary_exists gh; then
|
||||||
if _command_exists brew; then
|
# If gh already completed, stop
|
||||||
_log_warning "You don't need github-cli completion enabled if you have system completion enabled"
|
_completion_exists gh && return
|
||||||
fi
|
eval "$(gh completion --shell=bash)"
|
||||||
eval "$(gh completion --shell=bash)"
|
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,13 +1,15 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
|
about-completion "completion for go command using gocomplete"
|
||||||
|
|
||||||
# bash completion for go tool
|
# bash completion for go tool
|
||||||
# https://github.com/posener/complete
|
# https://github.com/posener/complete
|
||||||
# https://pkg.go.dev/github.com/posener/complete?tab=doc
|
|
||||||
|
|
||||||
# Install gocomplete:
|
# Test `go version` because goenv creates shim scripts that will be found in PATH
|
||||||
# go get -u github.com/posener/complete/gocomplete
|
# but do not always resolve to a working install.
|
||||||
# gocomplete -install
|
if _command_exists go && go version &> /dev/null; then
|
||||||
|
# Same idea here, but no need to test a subcommand
|
||||||
if _command_exists gocomplete && _command_exists go ; then
|
if _command_exists gocomplete && gocomplete &> /dev/null; then
|
||||||
complete -C "${GOBIN}"/gocomplete go
|
# finally, apply completion
|
||||||
|
complete -C gocomplete go
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,18 +1,32 @@
|
||||||
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
# Copyright (c) 2017 Eric Wendelin
|
||||||
|
|
||||||
|
# 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.
|
||||||
|
|
||||||
# Bash breaks words on : by default. Subproject tasks have ':'
|
# Bash breaks words on : by default. Subproject tasks have ':'
|
||||||
# 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() {
|
||||||
|
|
@ -38,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"
|
||||||
|
|
@ -54,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
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,9 +3,35 @@
|
||||||
# grunt-cli
|
# grunt-cli
|
||||||
# http://gruntjs.com/
|
# http://gruntjs.com/
|
||||||
#
|
#
|
||||||
# Copyright (c) 2012 Tyler Kellen, contributors
|
# Copyright jQuery Foundation and other contributors, https://jquery.org/
|
||||||
# Licensed under the MIT license.
|
|
||||||
# https://github.com/gruntjs/grunt/blob/master/LICENSE-MIT
|
# This software consists of voluntary contributions made by many
|
||||||
|
# individuals. For exact contribution history, see the revision history
|
||||||
|
# available at https://github.com/gruntjs/grunt .
|
||||||
|
|
||||||
|
# The following license applies to all parts of this software except as
|
||||||
|
# documented below:
|
||||||
|
|
||||||
|
# ====
|
||||||
|
|
||||||
|
# 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.
|
||||||
|
|
||||||
# Usage:
|
# Usage:
|
||||||
#
|
#
|
||||||
|
|
|
||||||
|
|
@ -2,9 +2,36 @@
|
||||||
# Borrowed from grunt-cli
|
# Borrowed from grunt-cli
|
||||||
# http://gruntjs.com/
|
# http://gruntjs.com/
|
||||||
#
|
#
|
||||||
# Copyright (c) 2012 Tyler Kellen, contributors
|
# Copyright jQuery Foundation and other contributors, https://jquery.org/
|
||||||
# Licensed under the MIT license.
|
|
||||||
# https://github.com/gruntjs/grunt/blob/master/LICENSE-MIT
|
# This software consists of voluntary contributions made by many
|
||||||
|
# individuals. For exact contribution history, see the revision history
|
||||||
|
# available at https://github.com/gruntjs/grunt .
|
||||||
|
|
||||||
|
# The following license applies to all parts of this software except as
|
||||||
|
# documented below:
|
||||||
|
|
||||||
|
# ====
|
||||||
|
|
||||||
|
# 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.
|
||||||
|
|
||||||
# Usage:
|
# Usage:
|
||||||
#
|
#
|
||||||
# To enable bash <tab> completion for gulp, add the following line (minus the
|
# To enable bash <tab> completion for gulp, add the following line (minus the
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,7 @@
|
||||||
#!/usr/bin/env bash
|
# shellcheck shell=bash
|
||||||
|
cite "about-completion"
|
||||||
|
about-completion "helm (Kubernetes Package Manager) completion"
|
||||||
|
|
||||||
# helm (Kubernetes Package Manager) completion
|
if _command_exists helm; then
|
||||||
|
eval "$(helm completion bash)"
|
||||||
if command -v helm &>/dev/null
|
|
||||||
then
|
|
||||||
eval "$(helm completion bash)"
|
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,60 +1,2 @@
|
||||||
# Bash completion script for homesick
|
_log_warning 'Bash completion for "homesick" is now deprecated, as it used unlicensed code.
|
||||||
#
|
Please disable this completion and use the instructions from "homesick" bash completion developers instead.'
|
||||||
# The homebrew bash completion script was used as inspiration.
|
|
||||||
# Originally from https://github.com/liborw/homesick-completion
|
|
||||||
|
|
||||||
_homesick_complete()
|
|
||||||
{
|
|
||||||
local cur="${COMP_WORDS[COMP_CWORD]}"
|
|
||||||
local options="--skip --force --pretend --quiet"
|
|
||||||
local actions="cd clone commit destroy diff generate help list open pull push rc show_path status symlink track unlink version"
|
|
||||||
local repos=$(\ls ~/.homesick/repos)
|
|
||||||
|
|
||||||
# Subcommand list
|
|
||||||
[[ ${COMP_CWORD} -eq 1 ]] && {
|
|
||||||
COMPREPLY=( $(compgen -W "${options} ${actions}" -- ${cur}) )
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
# Find the first non-switch word
|
|
||||||
local prev_index=1
|
|
||||||
local prev="${COMP_WORDS[prev_index]}"
|
|
||||||
while [[ $prev == -* ]]; do
|
|
||||||
prev_index=$((++prev_index))
|
|
||||||
prev="${COMP_WORDS[prev_index]}"
|
|
||||||
done
|
|
||||||
|
|
||||||
# Find the number of non-"--" commands
|
|
||||||
local num=0
|
|
||||||
for word in ${COMP_WORDS[@]}
|
|
||||||
do
|
|
||||||
if [[ $word != -* ]]; then
|
|
||||||
num=$((++num))
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
case "$prev" in
|
|
||||||
# Commands that take a castle
|
|
||||||
cd|commit|destroy|diff|open|pull|push|rc|show_path|status|symlink|unlink)
|
|
||||||
COMPREPLY=( $(compgen -W "${repos}" -- ${cur}) )
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
# Commands that take command
|
|
||||||
help)
|
|
||||||
COMPREPLY=( $(compgen -W "${actions}" -- ${cur}) )
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
# Track command take file and repo
|
|
||||||
track)
|
|
||||||
if [[ "$num" -eq 2 ]]; then
|
|
||||||
COMPREPLY=( $(compgen -X -f ${cur}) )
|
|
||||||
elif [[ "$num" -ge 3 ]]; then
|
|
||||||
COMPREPLY=( $(compgen -W "${repos}" -- ${cur}) )
|
|
||||||
fi
|
|
||||||
return
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
}
|
|
||||||
|
|
||||||
complete -o bashdefault -o default -F _homesick_complete homesick
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,13 +1,34 @@
|
||||||
# hub tab-completion script for bash.
|
# hub tab-completion script for bash.
|
||||||
# This script complements the completion script that ships with git.
|
# This script complements the completion script that ships with git.
|
||||||
|
|
||||||
|
# Copyright (c) 2009 Chris Wanstrath
|
||||||
|
|
||||||
|
# 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.
|
||||||
|
|
||||||
# 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/')"
|
||||||
|
|
@ -206,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)
|
||||||
|
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue