mirror of
https://github.com/ivuorinen/dotfiles.git
synced 2026-02-01 20:47:42 +00:00
Compare commits
595 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| c5e06888b8 | |||
|
|
4f138eee73 | ||
|
|
90258e5105 | ||
| efc53fc9bf | |||
|
|
f62c17d940 | ||
|
|
fb15b93887 | ||
|
|
222276486a | ||
|
|
4446d59e73 | ||
| a22709a0f0 | |||
| 76598ad33b | |||
| 56ccb7c136 | |||
|
|
b6d933d018 | ||
| f9856a27b9 | |||
| b36b52ad57 | |||
| 1e60ccf49b | |||
|
|
9ca9439b9a | ||
| 6d30ae7e84 | |||
| 031e124663 | |||
| bb50c9fe18 | |||
| 8e608de501 | |||
|
|
8917b7736b | ||
| 18ff879f1d | |||
| c5a258d7be | |||
| 7525f1f71d | |||
| 3b665bdba0 | |||
| 99477364bd | |||
|
|
629fdf6d4c | ||
| 1288599b1f | |||
| be3a68fecb | |||
| 101e4da1d6 | |||
| 23430a609a | |||
| bb0d56e403 | |||
| d3b08bdf4f | |||
| e1ec501c55 | |||
| f92c3407f0 | |||
| b5971439b6 | |||
| 8ea8a2797a | |||
| b0f9222482 | |||
| 825ccc1031 | |||
| dab7a8a38a | |||
| 1dbc7ae5cd | |||
| 7038da568e | |||
| bfcaa26070 | |||
| f6488aecce | |||
| ad166e8012 | |||
| 2a76a414a0 | |||
| bb8ddf0bba | |||
| bf3e746010 | |||
|
|
b9957e4f0e | ||
| e1deba4ccf | |||
| 36e4de3035 | |||
| 3eab1faeab | |||
| 1eb4098646 | |||
| f7db8cae15 | |||
| 97dd3dc21d | |||
| 6da6797f1b | |||
|
|
88356f1392 | ||
| 174bb842e9 | |||
| f6e7590118 | |||
| 498996a6e2 | |||
| 0961985fb4 | |||
| 293452604d | |||
|
|
9582f18c7d | ||
| 051e3604ee | |||
| 09d62dd159 | |||
| 8a3763e168 | |||
| c37793f649 | |||
| 7bc7230990 | |||
| 067df4e34b | |||
| 4d28499423 | |||
| b685af82fb | |||
|
|
b8a4b82431 | ||
| 0b03acebd8 | |||
| d172b86cb8 | |||
| f910dfb9ac | |||
| ee95d57ba0 | |||
| f8a317f3c7 | |||
| 3762e10932 | |||
| afda96902b | |||
| 3060b6ad66 | |||
|
|
4f154cf509 | ||
| 863d803483 | |||
| 07bb2b56d1 | |||
| 84a753100e | |||
| c8b01f3fda | |||
| 8e6a110aac | |||
| a8baa1671f | |||
| 2ccdd042f6 | |||
|
|
8cf43ed555 | ||
| e22094e0da | |||
| 6186c5cba4 | |||
| c453dcbf84 | |||
| 4daaa62aed | |||
| f56d5682d1 | |||
| 439638b686 | |||
| a8a473a46d | |||
| eb91a43bbd | |||
|
|
193fae662e | ||
|
|
117ca1a944 | ||
| 1f1a6d42ad | |||
| cca265cd99 | |||
| cc6abb53ba | |||
| ab34c148a6 | |||
|
|
910b29ed9f | ||
| 3fb0a75a62 | |||
|
|
f73abb508b | ||
|
|
1dd3d952cf | ||
| 1ffd6e1569 | |||
| a76033a48a | |||
| 34dc18883e | |||
| 832d8b94f3 | |||
| c40eb765f8 | |||
|
|
1bb7e9076b | ||
|
|
17821dfefa | ||
| 19327947ed | |||
| 2356fc4c61 | |||
| 45219deccb | |||
| 5471aba1a4 | |||
|
|
6f6ee3611c | ||
|
|
d8f9cdf265 | ||
| abb6de05be | |||
| 60ef48e918 | |||
| e58c79a3c3 | |||
| d47f21286d | |||
| 3f108c9353 | |||
|
|
4a68146786 | ||
|
|
cf79e61943 | ||
| 43dcb303a0 | |||
| 1b03f0bbd6 | |||
| 8a52c9a97e | |||
| 8e84c3aef7 | |||
| acd2f7fc6d | |||
| 1e4aa1558a | |||
| b314c0ba76 | |||
| ece46561c4 | |||
| 196d217c34 | |||
| 7d2fc55791 | |||
| 74fb12f093 | |||
|
|
d7988bcad7 | ||
| 320ae35dcd | |||
| 0964253be5 | |||
|
|
f3f7ecc522 | ||
|
|
b88de0c3ae | ||
| c5e6860595 | |||
| b5a3c34fc3 | |||
| 87c89cf828 | |||
|
|
8d57c9425e | ||
|
|
cfe97d81a7 | ||
| 2f13ad324a | |||
|
|
d203fc9d51 | ||
| bf279b6def | |||
| 87926f8d9b | |||
| 6b056f6072 | |||
| 823cdbc07f | |||
| 0f6157eb04 | |||
| 721fe614a7 | |||
| 5ea16d4653 | |||
| 900e6a8f85 | |||
| 16673de789 | |||
| c732a75184 | |||
|
|
96280e6e9b | ||
| 5ab0f89765 | |||
| d585d61537 | |||
| 746646ae55 | |||
|
|
6e69ec6410 | ||
| af123e5138 | |||
| 3879289559 | |||
| 392628e733 | |||
| aa70eab5fb | |||
| e5311ca285 | |||
| d5618c9b5f | |||
| d091f5a88f | |||
| cb9195e3ad | |||
| c91cc387b6 | |||
| 083091ea46 | |||
| 7ff74f0e15 | |||
| 9d1f62fcca | |||
| a563e82e33 | |||
| 62ff7836e7 | |||
| 88cb573027 | |||
| 82772d8208 | |||
|
|
240035569c | ||
|
|
9697c200f9 | ||
| fd11f9966b | |||
| 722b3c0cde | |||
| 4fcb9d9741 | |||
| fc232f26f7 | |||
| 8b078309cf | |||
| 5a8f990e52 | |||
| c76c5d08b0 | |||
| b2857e226c | |||
| dfbac0c736 | |||
| fdd713908c | |||
| 60210c9bec | |||
| eaf8d2bdca | |||
| cc00055626 | |||
|
|
567de68844 | ||
|
|
ed0b229757 | ||
| c8b6243c0b | |||
|
|
21a92eb145 | ||
| 8ec317f582 | |||
|
|
42201d8b68 | ||
|
|
0c003ae5b9 | ||
| d383031ec8 | |||
|
|
fa5e5f16da | ||
| f82396236e | |||
| b127c2514d | |||
|
|
b06ac3bc0f | ||
|
|
7e4ea90a05 | ||
|
|
d264a33d21 | ||
| 224ee56461 | |||
|
|
8147490c65 | ||
|
|
c6d501347a | ||
|
|
d8044f2b6a | ||
|
|
1b3fe6d12e | ||
| 76b66d8c61 | |||
| 9c8644de17 | |||
| 120345b562 | |||
| 8accd4a60b | |||
| 8fb03660ad | |||
| 8b2dc74f2a | |||
| 8fa63e63bb | |||
| 4ca5b63b75 | |||
| 5a59872377 | |||
| 38419eda28 | |||
| fc85dbaa6c | |||
| 250e7f5666 | |||
| 8f96922033 | |||
| 4c4de2dc26 | |||
| b8c163e028 | |||
| 0a974c2a17 | |||
| fd8d72ab38 | |||
| 0908a23231 | |||
| 2e070eed83 | |||
| e22762255d | |||
| 093f58f129 | |||
| 9b6e39b4af | |||
|
|
6f1e1a0416 | ||
| 36e0f36e06 | |||
| e2c37d29e8 | |||
| 78716fa8ce | |||
| 81e9b20eb6 | |||
|
|
94e58b307b | ||
| 98aca096a9 | |||
| 121e31c7d4 | |||
| f6bcd10ac5 | |||
| 619c772fcc | |||
| 746d44151c | |||
| b9585209be | |||
| 930dcf00c4 | |||
| bb8e3bba56 | |||
| 6431c2e6dc | |||
| 248eca1ae6 | |||
| 4b1ab2e1b8 | |||
| c0f537439b | |||
| 9ab132d37c | |||
| 2b9ddc232b | |||
| 1a244ce0b1 | |||
| fdc0f45b23 | |||
| 3fa90eef3b | |||
| 7ea7c12f0b | |||
| f76492b942 | |||
| 7947340663 | |||
| 300c48b1e9 | |||
| 772527cc66 | |||
|
|
370fdcbcbe | ||
| b32c86bac2 | |||
| 8d85809b1c | |||
| 7fc40e3eab | |||
|
|
1aca769ebf | ||
| 57df4edf6c | |||
| 240ac35aa8 | |||
| ad0ba59b67 | |||
| bbc26e66dd | |||
| 1803d41969 | |||
| 34d547433f | |||
| dff4b9a9c5 | |||
| c33404eb27 | |||
| 99e7578d60 | |||
| d8011728c7 | |||
| 2f67d4a2e2 | |||
|
|
ef37681087 | ||
|
|
0c014033d1 | ||
|
|
14635009d2 | ||
| 70118fee52 | |||
|
|
0dce28ea6a | ||
| ba15f82302 | |||
| d4972ea30d | |||
| ed7263dfee | |||
| 4cda063305 | |||
| d251ea9cdc | |||
| bc4e906ff6 | |||
| 75c36bacf9 | |||
| e7cda5ac0c | |||
| 41024b1eb5 | |||
| 74afeb61c8 | |||
| 104bc369bc | |||
| 57e63847ce | |||
| 2dc08e5e51 | |||
| 989b5b5111 | |||
| 24a5dd1ff6 | |||
| 5826e35853 | |||
| e329868568 | |||
| dc76fa8914 | |||
| 3413365d41 | |||
| 37299f4893 | |||
| 71a78c6e0c | |||
| 3f8a4deb05 | |||
| ffe288aba3 | |||
| 28a1fc2831 | |||
| 28aae89f70 | |||
| e8fe5c570b | |||
| 26f6024292 | |||
| 4e4692321b | |||
| 3ea221ccf9 | |||
| e7774c4ab1 | |||
| 1f2ca90ca5 | |||
| adecceda7a | |||
| 8a3b2e703c | |||
| 1ee726e30c | |||
| 9857c8eb00 | |||
| a919d9544e | |||
| 7bc7921a17 | |||
| 735807f245 | |||
| 6d531e2d40 | |||
| 77f89c0f48 | |||
| 7f3c7b7e1c | |||
| fc16b8231e | |||
| 64a626d5c4 | |||
| 54816c2ce9 | |||
| 3acaea5611 | |||
| e4a313abe7 | |||
| 0b1c75cbdd | |||
| cab0f4da49 | |||
| cef15eddce | |||
| f8987818b8 | |||
|
|
15d1f6a59a | ||
| ba586fca7d | |||
|
|
d93bc7aae3 | ||
| 77b0428cec | |||
| 387432b27b | |||
| 88fa706b75 | |||
| 96ce9fec0c | |||
| 66d5fbc8ac | |||
| cc3ceb4176 | |||
| 0f9c69bb65 | |||
| c754746b9f | |||
| df5cab6a88 | |||
| b9ddba4666 | |||
| 77e92ef15e | |||
| 383bc2b052 | |||
| 0e109c3da3 | |||
| 50abd5aa30 | |||
| 082e27fb0a | |||
| e05e68f5d1 | |||
| 074c169e3c | |||
| 636ea749ac | |||
| da2a2e0f81 | |||
| 0ef12b61ac | |||
| c6fc3db52f | |||
| 1bde81a673 | |||
| d60248f356 | |||
| 40e8b9443b | |||
| 8a032a2804 | |||
| 367be373c4 | |||
| cf2f98d5c0 | |||
| a3704f7db9 | |||
| 7c359ffea0 | |||
| 9542624323 | |||
|
|
b0d74bad1a | ||
| fcade15933 | |||
| 6860909d39 | |||
| 493ad17c15 | |||
|
|
0495ac1ea8 | ||
| 9b5d372a74 | |||
| 9d04343a26 | |||
|
|
4aa0fba682 | ||
| ad6482b34a | |||
| 113e27734a | |||
| 378abfe896 | |||
| eadf1e5c84 | |||
| ea4d185fb4 | |||
| 22bd8ca870 | |||
| 7ee81b005c | |||
| 3faf8224e8 | |||
| d028f37c00 | |||
| 1df05ac0ba | |||
| e54e202281 | |||
| c226943aa9 | |||
| dda4b65458 | |||
| 7d564d0b4d | |||
| bc30e5f7a6 | |||
| 9e2f7e8f1b | |||
| 7b47e49804 | |||
| 1be7649122 | |||
| 453d54bc7f | |||
| 7ede7b9ac1 | |||
| a90743a09c | |||
| 185d28e587 | |||
|
|
37f023351d | ||
| 39523e9234 | |||
|
|
1f8fc0d289 | ||
| c083d2a20a | |||
| 75c6a0bccd | |||
| 5ce86b3229 | |||
| 885189e4ff | |||
| 8f3f4d7ed9 | |||
| 03a1b5fb85 | |||
| 7b83f6e943 | |||
| 261ff41e28 | |||
| 36ad2a2ad9 | |||
|
|
a4d5b87272 | ||
| f953bff183 | |||
| aba33a20a4 | |||
| a20e1e1419 | |||
| 8328f4cd19 | |||
| 4383b130a9 | |||
| 8143999f2a | |||
| 523bec769f | |||
| dee215a29e | |||
| 755ac0fa2c | |||
| a69f1f9f9c | |||
| 934ecb2335 | |||
| 4b6b887ca8 | |||
| fb0b9044eb | |||
| 74ca882192 | |||
| b904f0b60e | |||
| 13764775ca | |||
| 1f7b92285b | |||
| 1f22aee5e3 | |||
| 7dddf3ed75 | |||
| 62cd8cbda4 | |||
| 7dcebc8615 | |||
| 2e6a1582bf | |||
| c316a8eb2f | |||
| 4a493abedf | |||
| a395397a02 | |||
| 33f839c842 | |||
| 8b55ac1bba | |||
| 856ca00f1b | |||
| c5bbe4add5 | |||
| d2904274cb | |||
| 7ce8c78920 | |||
| 71301a6436 | |||
| e4f925e5b0 | |||
| 63ebd6df47 | |||
| d598aade16 | |||
| 1b49de9645 | |||
| d56338e233 | |||
| ef6ccb92c0 | |||
| 16bb91dd81 | |||
| e7f078fe96 | |||
| 49778fe936 | |||
| 6a718a41b1 | |||
| f392938e9e | |||
| 7fb38fe8f3 | |||
| 639cbe4939 | |||
| 1dc84a9cc5 | |||
| 6ae753d257 | |||
| b7c9d4851a | |||
| 4699233d46 | |||
| a5895abfa0 | |||
| fae34d10ef | |||
| c0448b5e7f | |||
| 4d7cc568af | |||
| 01a2815a68 | |||
| 39e896f331 | |||
| 622c8f991a | |||
| 88894a33a5 | |||
| acbfd34e7d | |||
| bac03a0b7b | |||
| a96bf921a2 | |||
| b5df60851f | |||
| 2e682c58fa | |||
| cb28e274ca | |||
| 4572c42eea | |||
| cec1edb269 | |||
| bfe7e93b60 | |||
| 1b80c8b7ed | |||
| c7c3493259 | |||
| 0e797d36ae | |||
|
|
0beb386f4a | ||
|
|
cc0e668cd9 | ||
|
|
d6f7aecf6c | ||
|
|
5253b69e37 | ||
| 12080f59e1 | |||
| 614827a877 | |||
| 09343033ec | |||
| c24f51adb9 | |||
| 1a74cf78c1 | |||
| e31948dcc5 | |||
| 25acc678d8 | |||
| 8c3796b433 | |||
| 048c9ac64f | |||
| 4ef3369c0e | |||
| b9c343dc27 | |||
| cfb41b8a03 | |||
| e42edc2dcf | |||
| 5a95484c58 | |||
| 988cb9cd18 | |||
|
|
681396383a | ||
|
|
f1aaf65e93 | ||
| 83bdfbf6a2 | |||
| 08c2be6f97 | |||
|
|
acf0bbe659 | ||
| e4bae620fa | |||
| b81c8f05b5 | |||
| 56427a08a8 | |||
| f2e7864583 | |||
| 9f96d553f0 | |||
| 1dee09759a | |||
| e2f6db9208 | |||
| 14270093c2 | |||
| 5015a8cd5a | |||
| 266c18e195 | |||
| 9c432ed2a0 | |||
| e6f3aae287 | |||
| a73c54a5a6 | |||
| 39ecd0495c | |||
| 4b45c89a90 | |||
| dfb7a51786 | |||
| 56ae0e1e1c | |||
| 3d753fe08c | |||
| 540054d4bb | |||
| b1a7932b72 | |||
| ced09160ab | |||
| 594ee0d03c | |||
| 68ec53e29b | |||
| 0c8b075689 | |||
| 0242bbbd73 | |||
| 31423c30b9 | |||
| fbdd2c7448 | |||
| 0aff4784b1 | |||
| 10b18e8bcc | |||
| dc0a349139 | |||
| 3ac1fac444 | |||
| 5bf4ea462b | |||
| 1d056988f4 | |||
| 2415dff0e2 | |||
| d891d5a3c5 | |||
| f48813ff85 | |||
| a87b33b8c2 | |||
| 6f854ddbfd | |||
| 748e5bb561 | |||
| 67867b57cd | |||
| 91734ffa15 | |||
| 5364bef678 | |||
| 50b4f5c60f | |||
| 7cd508a727 | |||
| bf2c665433 | |||
| f5b1bf0915 | |||
| e0c6d7e4f4 | |||
| 1937e72f17 | |||
| 228ba78341 | |||
| c8c34dcc81 | |||
| 3d65fdee43 | |||
| 1897f49906 | |||
| d86785ad47 | |||
| 1c3c04a6f3 | |||
| debb79ee09 | |||
| c1dda8a230 | |||
| 5c74383dda | |||
| da1473547a | |||
| 43df368ec1 | |||
| 6f3f977100 | |||
| ab8e654c2a | |||
| 1a4113e3cd | |||
| b3445d7e7a | |||
| 50fc1ea279 | |||
| d61f53196d | |||
| 7769af68b5 | |||
| 05aa4ba092 | |||
| a26f160326 | |||
| 00de4a7b83 | |||
| 020012eb60 | |||
| cf92bc9a69 | |||
| 1c17ee28cb | |||
| 0919a9732e | |||
| 52a941f0fa | |||
| e661f6d942 | |||
| b5160bbbfa | |||
| 2df27d2a0e | |||
|
|
0c0f3823e4 | ||
|
|
5fb433f7ac | ||
| 0fc08678a2 | |||
| ff83bc9ef1 | |||
| 492cb4dbd8 | |||
| bc608cd578 | |||
| acae4fec73 | |||
| 446d8971e7 | |||
| 2f917c9285 | |||
| 1d851708eb | |||
|
|
c3d4b51927 | ||
| 6d8c04977c | |||
| 64fc8a13d3 |
1
.browserslistrc
Normal file
1
.browserslistrc
Normal file
@@ -0,0 +1 @@
|
|||||||
|
extends @ivuorinen/browserslist-config
|
||||||
3
.commitlintrc.json
Normal file
3
.commitlintrc.json
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"extends": ["@ivuorinen/commitlint-config"]
|
||||||
|
}
|
||||||
@@ -8,6 +8,12 @@ indent_style = space
|
|||||||
insert_final_newline = true
|
insert_final_newline = true
|
||||||
trim_trailing_whitespace = true
|
trim_trailing_whitespace = true
|
||||||
|
|
||||||
|
[*.md]
|
||||||
|
max_line_length = 100
|
||||||
|
|
||||||
|
[*.lua]
|
||||||
|
max_line_length = 120
|
||||||
|
|
||||||
[*.php]
|
[*.php]
|
||||||
indent_size = 4
|
indent_size = 4
|
||||||
|
|
||||||
@@ -19,11 +25,19 @@ indent_size = 1
|
|||||||
indent_size = 1
|
indent_size = 1
|
||||||
indent_style = tab
|
indent_style = tab
|
||||||
|
|
||||||
[local/bin/*]
|
[{local/bin/*,**/*.sh,**/zshrc,config/*,scripts/*}]
|
||||||
|
indent_size = 2
|
||||||
|
tab_width = 2
|
||||||
shell_variant = bash # --language-variant
|
shell_variant = bash # --language-variant
|
||||||
binary_next_line = true
|
binary_next_line = true
|
||||||
switch_case_indent = true # --case-indent
|
switch_case_indent = true # --case-indent
|
||||||
space_redirects = true
|
space_redirects = true
|
||||||
keep_padding = true
|
keep_padding = false
|
||||||
function_next_line = true # --func-next-line
|
function_next_line = true # --func-next-line
|
||||||
|
|
||||||
|
# Ignore the entire "third_party" directory when calling shfmt on directories,
|
||||||
|
# such as "shfmt -l -w .". When formatting files directly,
|
||||||
|
# like "shfmt -w third_party/foo.sh" or "shfmt --filename=third_party/foo.sh",
|
||||||
|
# the ignore logic is applied only when the --apply-ignore flag is given.
|
||||||
|
[{tools/**,local/bin/asdf/**,config/cheat/cheatsheets/**,config/tmux/plugins/**}]
|
||||||
|
ignore = true
|
||||||
|
|||||||
3
.eslintrc.json
Normal file
3
.eslintrc.json
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"extends": ["@ivuorinen"]
|
||||||
|
}
|
||||||
7
.gitattributes
vendored
7
.gitattributes
vendored
@@ -13,7 +13,7 @@
|
|||||||
## Handle line endings automatically for files detected as
|
## Handle line endings automatically for files detected as
|
||||||
## text and leave all files detected as binary untouched.
|
## text and leave all files detected as binary untouched.
|
||||||
## This will handle all files NOT defined below.
|
## This will handle all files NOT defined below.
|
||||||
* text=auto
|
* text=auto oel=lf
|
||||||
|
|
||||||
# Source code
|
# Source code
|
||||||
*.bash text eol=lf
|
*.bash text eol=lf
|
||||||
@@ -220,8 +220,3 @@ git/* text
|
|||||||
**/alias text
|
**/alias text
|
||||||
ssh/* text
|
ssh/* text
|
||||||
|
|
||||||
# Git Crypt special files
|
|
||||||
*-secret filter=git-crypt diff=git-crypt
|
|
||||||
*.key filter=git-crypt diff=git-crypt
|
|
||||||
secrets/** filter=git-crypt diff=git-crypt
|
|
||||||
|
|
||||||
|
|||||||
1
.github/CODEOWNERS
vendored
Normal file
1
.github/CODEOWNERS
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
* @ivuorinen
|
||||||
128
.github/CODE_OF_CONDUCT.md
vendored
Normal file
128
.github/CODE_OF_CONDUCT.md
vendored
Normal file
@@ -0,0 +1,128 @@
|
|||||||
|
# Contributor Covenant Code of Conduct
|
||||||
|
|
||||||
|
## Our Pledge
|
||||||
|
|
||||||
|
We as members, contributors, and leaders pledge to make participation in our
|
||||||
|
community a harassment-free experience for everyone, regardless of age, body
|
||||||
|
size, visible or invisible disability, ethnicity, sex characteristics, gender
|
||||||
|
identity and expression, level of experience, education, socio-economic status,
|
||||||
|
nationality, personal appearance, race, religion, or sexual identity
|
||||||
|
and orientation.
|
||||||
|
|
||||||
|
We pledge to act and interact in ways that contribute to an open, welcoming,
|
||||||
|
diverse, inclusive, and healthy community.
|
||||||
|
|
||||||
|
## Our Standards
|
||||||
|
|
||||||
|
Examples of behavior that contributes to a positive environment for our
|
||||||
|
community include:
|
||||||
|
|
||||||
|
- Demonstrating empathy and kindness toward other people
|
||||||
|
- Being respectful of differing opinions, viewpoints, and experiences
|
||||||
|
- Giving and gracefully accepting constructive feedback
|
||||||
|
- Accepting responsibility and apologizing to those affected by our mistakes,
|
||||||
|
and learning from the experience
|
||||||
|
- Focusing on what is best not just for us as individuals, but for the
|
||||||
|
overall community
|
||||||
|
|
||||||
|
Examples of unacceptable behavior include:
|
||||||
|
|
||||||
|
- The use of sexualized language or imagery, and sexual attention or
|
||||||
|
advances of any kind
|
||||||
|
- Trolling, insulting or derogatory comments, and personal or political attacks
|
||||||
|
- Public or private harassment
|
||||||
|
- Publishing others' private information, such as a physical or email
|
||||||
|
address, without their explicit permission
|
||||||
|
- Other conduct which could reasonably be considered inappropriate in a
|
||||||
|
professional setting
|
||||||
|
|
||||||
|
## Enforcement Responsibilities
|
||||||
|
|
||||||
|
Community leaders are responsible for clarifying and enforcing our standards of
|
||||||
|
acceptable behavior and will take appropriate and fair corrective action in
|
||||||
|
response to any behavior that they deem inappropriate, threatening, offensive,
|
||||||
|
or harmful.
|
||||||
|
|
||||||
|
Community leaders have the right and responsibility to remove, edit, or reject
|
||||||
|
comments, commits, code, wiki edits, issues, and other contributions that are
|
||||||
|
not aligned to this Code of Conduct, and will communicate reasons for moderation
|
||||||
|
decisions when appropriate.
|
||||||
|
|
||||||
|
## Scope
|
||||||
|
|
||||||
|
This Code of Conduct applies within all community spaces, and also applies when
|
||||||
|
an individual is officially representing the community in public spaces.
|
||||||
|
Examples of representing our community include using an official e-mail address,
|
||||||
|
posting via an official social media account, or acting as an appointed
|
||||||
|
representative at an online or offline event.
|
||||||
|
|
||||||
|
## Enforcement
|
||||||
|
|
||||||
|
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
||||||
|
reported to the community leaders responsible for enforcement at
|
||||||
|
ismo@ivuorinen.net.
|
||||||
|
All complaints will be reviewed and investigated promptly and fairly.
|
||||||
|
|
||||||
|
All community leaders are obligated to respect the privacy and security of the
|
||||||
|
reporter of any incident.
|
||||||
|
|
||||||
|
## Enforcement Guidelines
|
||||||
|
|
||||||
|
Community leaders will follow these Community Impact Guidelines in determining
|
||||||
|
the consequences for any action they deem in violation of this Code of Conduct:
|
||||||
|
|
||||||
|
### 1. Correction
|
||||||
|
|
||||||
|
**Community Impact**: Use of inappropriate language or other behavior deemed
|
||||||
|
unprofessional or unwelcome in the community.
|
||||||
|
|
||||||
|
**Consequence**: A private, written warning from community leaders, providing
|
||||||
|
clarity around the nature of the violation and an explanation of why the
|
||||||
|
behavior was inappropriate. A public apology may be requested.
|
||||||
|
|
||||||
|
### 2. Warning
|
||||||
|
|
||||||
|
**Community Impact**: A violation through a single incident or series
|
||||||
|
of actions.
|
||||||
|
|
||||||
|
**Consequence**: A warning with consequences for continued behavior. No
|
||||||
|
interaction with the people involved, including unsolicited interaction with
|
||||||
|
those enforcing the Code of Conduct, for a specified period of time. This
|
||||||
|
includes avoiding interactions in community spaces as well as external channels
|
||||||
|
like social media. Violating these terms may lead to a temporary or
|
||||||
|
permanent ban.
|
||||||
|
|
||||||
|
### 3. Temporary Ban
|
||||||
|
|
||||||
|
**Community Impact**: A serious violation of community standards, including
|
||||||
|
sustained inappropriate behavior.
|
||||||
|
|
||||||
|
**Consequence**: A temporary ban from any sort of interaction or public
|
||||||
|
communication with the community for a specified period of time. No public or
|
||||||
|
private interaction with the people involved, including unsolicited interaction
|
||||||
|
with those enforcing the Code of Conduct, is allowed during this period.
|
||||||
|
Violating these terms may lead to a permanent ban.
|
||||||
|
|
||||||
|
### 4. Permanent Ban
|
||||||
|
|
||||||
|
**Community Impact**: Demonstrating a pattern of violation of community
|
||||||
|
standards, including sustained inappropriate behavior, harassment of an
|
||||||
|
individual, or aggression toward or disparagement of classes of individuals.
|
||||||
|
|
||||||
|
**Consequence**: A permanent ban from any sort of public interaction within
|
||||||
|
the community.
|
||||||
|
|
||||||
|
## Attribution
|
||||||
|
|
||||||
|
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
|
||||||
|
version 2.0, available at
|
||||||
|
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
|
||||||
|
|
||||||
|
Community Impact Guidelines were inspired by [Mozilla's code of conduct
|
||||||
|
enforcement ladder](https://github.com/mozilla/diversity).
|
||||||
|
|
||||||
|
[homepage]: https://www.contributor-covenant.org
|
||||||
|
|
||||||
|
For answers to common questions about this code of conduct, see the FAQ at
|
||||||
|
https://www.contributor-covenant.org/faq. Translations are available at
|
||||||
|
https://www.contributor-covenant.org/translations.
|
||||||
76
.github/README.md
vendored
76
.github/README.md
vendored
@@ -6,7 +6,10 @@ aware of yet. As I find more interesting tools, configs and other stuff,
|
|||||||
this repository will live accordingly.
|
this repository will live accordingly.
|
||||||
|
|
||||||
Please for the love of everything good do not use these 1:1 as your own dotfiles,
|
Please for the love of everything good do not use these 1:1 as your own dotfiles,
|
||||||
fork or download the repo as a zip and go from there with your own configs.
|
fork or download the repository as a zip and go from there with your own configs.
|
||||||
|
|
||||||
|
It would be nice if you'd add an issue linking to your fork or repo so I can
|
||||||
|
see what interesting stuff you've done with it. Sharing is caring.
|
||||||
|
|
||||||
## Setup
|
## Setup
|
||||||
|
|
||||||
@@ -23,21 +26,19 @@ fork or download the repo as a zip and go from there with your own configs.
|
|||||||
|
|
||||||
## The looks
|
## The looks
|
||||||
|
|
||||||
## tmux with powerlevel10k, the default view
|

|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
## tmux + nvim (astronvim) editing this repository
|

|
||||||
|
|
||||||

|
|
||||||
|
|
||||||
## Interesting files and locations
|
## Interesting files and locations
|
||||||
|
|
||||||
### Interesting folders
|
### Interesting folders
|
||||||
|
|
||||||
| Path | Description |
|
| Path | Description |
|
||||||
|---------------------|----------------------------------------------|
|
| ------------------- | -------------------------------------------- |
|
||||||
| `.github` | GitHub Repository configuration files. |
|
| `.github` | GitHub Repository configuration files, meta. |
|
||||||
| `hosts/{hostname}/` | Configs that should apply to that host only. |
|
| `hosts/{hostname}/` | Configs that should apply to that host only. |
|
||||||
| `local/bin` | Helper scripts that I've collected or wrote. |
|
| `local/bin` | Helper scripts that I've collected or wrote. |
|
||||||
| `scripts` | Setup scripts. |
|
| `scripts` | Setup scripts. |
|
||||||
@@ -45,15 +46,17 @@ fork or download the repo as a zip and go from there with your own configs.
|
|||||||
### dotfile folders
|
### dotfile folders
|
||||||
|
|
||||||
| Repo | Destination | Description |
|
| Repo | Destination | Description |
|
||||||
|-----------|-------------|---------------------------------------------|
|
| --------- | ----------- | ------------------------------------------- |
|
||||||
| `base/` | `.*` | `$HOME` level files. |
|
| `base/` | `.*` | `$HOME` level files. |
|
||||||
| `config/` | `.config/` | Configurations for applications. |
|
| `config/` | `.config/` | Configurations for applications. |
|
||||||
| `local/` | `.local/` | XDG Base folder: `bin`, `share` and `state` |
|
| `local/` | `.local/` | XDG Base folder: `bin`, `share` and `state` |
|
||||||
| `ssh/` | `.ssh/` | SSH Configurations. |
|
| `ssh/` | `.ssh/` | SSH Configurations. |
|
||||||
|
|
||||||
### dfm - the dotfiles manager
|
### `dfm` - the dotfiles manager
|
||||||
|
|
||||||
`.local/bin/dfm` is a shell script that has some tools that help with dotfiles management.
|
[`.local/bin/dfm`][dfm] is a shell script that has some tools that help with dotfiles management.
|
||||||
|
|
||||||
|
Running `dfm` gives you a list of available commands.
|
||||||
|
|
||||||
## Configuration
|
## Configuration
|
||||||
|
|
||||||
@@ -62,57 +65,14 @@ The folder structure follows [XDG Base Directory Specification][xdg] where possi
|
|||||||
### XDG Variables
|
### XDG Variables
|
||||||
|
|
||||||
| Env | Default | Short description |
|
| Env | Default | Short description |
|
||||||
|--------------------|----------------------|------------------------------------------------|
|
| ------------------ | -------------------- | ---------------------------------------------- |
|
||||||
| `$XDG_BIN_HOME` | `$HOME/.local/bin` | Local binaries |
|
| `$XDG_BIN_HOME` | `$HOME/.local/bin` | Local binaries |
|
||||||
| `$XDG_CONFIG_HOME` | `$HOME/.config` | User-specific configs |
|
| `$XDG_CONFIG_HOME` | `$HOME/.config` | User-specific configs |
|
||||||
| `$XDG_DATA_HOME` | `$HOME/.local/share` | User-specific data files |
|
| `$XDG_DATA_HOME` | `$HOME/.local/share` | User-specific data files |
|
||||||
| `$XDG_STATE_HOME` | `$HOME/.local/state` | App state that should persist between restarts |
|
| `$XDG_STATE_HOME` | `$HOME/.local/state` | App state that should persist between restarts |
|
||||||
|
|
||||||
#### XDG_BIN_HOME (`$HOME/.local/bin`)
|
Please see [docs/folders.md][docs-folders] for more information.
|
||||||
|
|
||||||
`$XDG_BIN_HOME` defines directory that contains local binaries.
|
|
||||||
|
|
||||||
User-specific executable files may be stored in `$HOME/.local/bin`.
|
|
||||||
Distributions should ensure this directory shows up in the UNIX `$PATH`
|
|
||||||
environment variable, at an appropriate place.
|
|
||||||
|
|
||||||
#### XDG_DATA_HOME (`$HOME/.local/share`)
|
|
||||||
|
|
||||||
`$XDG_DATA_HOME` defines the base directory relative to which
|
|
||||||
user-specific *data files* should be stored.
|
|
||||||
|
|
||||||
If `$XDG_DATA_HOME` is either not set or empty,
|
|
||||||
a default equal to `$HOME/.local/share` should be used.
|
|
||||||
|
|
||||||
#### XDG_CONFIG_HOME (`$HOME/.config`)
|
|
||||||
|
|
||||||
`$XDG_CONFIG_HOME` defines the base directory relative to which
|
|
||||||
user-specific *configuration files* should be stored.
|
|
||||||
|
|
||||||
If `$XDG_CONFIG_HOME` is either not set or empty,
|
|
||||||
a default equal to `$HOME/.config` should be used.
|
|
||||||
|
|
||||||
#### XDG_STATE_HOME (`$HOME/.local/state`)
|
|
||||||
|
|
||||||
`$XDG_STATE_HOME` defines the base directory relative to which
|
|
||||||
user-specific *state files* should be stored.
|
|
||||||
|
|
||||||
If `$XDG_STATE_HOME` is either not set or empty,
|
|
||||||
a default equal to `$HOME/.local/state` should be used.
|
|
||||||
|
|
||||||
The `$XDG_STATE_HOME` contains *state data* that should
|
|
||||||
*persist between (application) restarts*, but that is not important or
|
|
||||||
portable enough to the user that it should be stored in `$XDG_DATA_HOME`.
|
|
||||||
|
|
||||||
- It may contain:
|
|
||||||
- actions history (logs, history, recently used files, …)
|
|
||||||
- current state of the application that can be reused
|
|
||||||
on a restart (view, layout, open files, undo history, …)
|
|
||||||
|
|
||||||
#### XDG_DATA_DIRS
|
|
||||||
|
|
||||||
`$XDG_DATA_DIRS` defines the preference-ordered set of base directories
|
|
||||||
to search for data files in addition to the `$XDG_DATA_HOME` base directory.
|
|
||||||
The directories in `$XDG_DATA_DIRS` should be seperated with a colon ':'.
|
|
||||||
|
|
||||||
|
[dfm]: https://github.com/ivuorinen/dotfiles/blob/main/local/bin/dfm
|
||||||
|
[docs-folders]: https://github.com/ivuorinen/dotfiles/blob/main/docs/folders.md
|
||||||
[xdg]: https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
|
[xdg]: https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
|
||||||
|
|||||||
12
.github/SECURITY.md
vendored
Normal file
12
.github/SECURITY.md
vendored
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
# Security Policy
|
||||||
|
|
||||||
|
## Supported Versions
|
||||||
|
|
||||||
|
Usually only the latest daily tag is supported at all,
|
||||||
|
because that's the current I'm using.
|
||||||
|
|
||||||
|
## Reporting a Vulnerability
|
||||||
|
|
||||||
|
Please send me email directly to the email in my profile.
|
||||||
|
I'd appreciate link to the release the vulnerability was
|
||||||
|
found in, and what is the vulnerable code/dependency.
|
||||||
6
.github/dependabot.yml
vendored
6
.github/dependabot.yml
vendored
@@ -1,7 +1,7 @@
|
|||||||
version: 2
|
version: 2
|
||||||
updates:
|
updates:
|
||||||
# Maintain dependencies for GitHub Actions
|
# Maintain dependencies for GitHub Actions
|
||||||
- package-ecosystem: "github-actions"
|
- package-ecosystem: 'github-actions'
|
||||||
directory: "/"
|
directory: '/'
|
||||||
schedule:
|
schedule:
|
||||||
interval: "weekly"
|
interval: 'weekly'
|
||||||
|
|||||||
4
.github/renovate.json
vendored
4
.github/renovate.json
vendored
@@ -1,6 +1,4 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
|
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
|
||||||
"extends": [
|
"extends": ["local>ivuorinen/renovate-config"]
|
||||||
"local>ivuorinen/.github:renovate-config"
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
|||||||
BIN
.github/screenshots/oh-my-posh.png
vendored
Normal file
BIN
.github/screenshots/oh-my-posh.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 45 KiB |
BIN
.github/screenshots/tmux-nvim-kickstart-dark.png
vendored
Normal file
BIN
.github/screenshots/tmux-nvim-kickstart-dark.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 85 KiB |
BIN
.github/screenshots/tmux-nvim-kickstart-light.png
vendored
Normal file
BIN
.github/screenshots/tmux-nvim-kickstart-light.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 87 KiB |
BIN
.github/screenshots/tmux-nvim.png
vendored
Normal file
BIN
.github/screenshots/tmux-nvim.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 109 KiB |
17
.github/tag-changelog-config.js
vendored
17
.github/tag-changelog-config.js
vendored
@@ -7,20 +7,21 @@ module.exports = {
|
|||||||
{ types: ['build', 'ci'], label: '🏗️ Build System' },
|
{ types: ['build', 'ci'], label: '🏗️ Build System' },
|
||||||
{ types: ['refactor'], label: '🪚 Refactors' },
|
{ types: ['refactor'], label: '🪚 Refactors' },
|
||||||
{ types: ['doc', 'docs'], label: '📚 Documentation Changes' },
|
{ types: ['doc', 'docs'], label: '📚 Documentation Changes' },
|
||||||
|
{ types: ['config'], label: '🪛 Configuration Changes' },
|
||||||
{ types: ['test', 'tests'], label: '🔍 Tests' },
|
{ types: ['test', 'tests'], label: '🔍 Tests' },
|
||||||
{ types: ['style', 'codestyle'], label: '💅 Code Style Changes' },
|
{ types: ['style', 'codestyle', 'lint'], label: '💅 Code Style Changes' },
|
||||||
{ types: ['chore', 'Chore'], label: '🧹 Chores' },
|
{ types: ['chore', 'Chore', 'deps', 'Deps'], label: '🧹 Chores' },
|
||||||
{ types: ['other', 'Other'], label: 'Other Changes' },
|
{ types: ['other', 'Other'], label: 'Other Changes' },
|
||||||
],
|
],
|
||||||
|
|
||||||
excludeTypes: [],
|
excludeTypes: [],
|
||||||
|
|
||||||
renderTypeSection: function (label, commits) {
|
renderTypeSection: function (label, commits) {
|
||||||
let text = `\n## ${ label }\n\n`
|
let text = `\n## ${label}\n\n`
|
||||||
|
|
||||||
commits.forEach((commit) => {
|
commits.forEach(commit => {
|
||||||
const scope = commit.scope ? `**${ commit.scope }:** ` : ''
|
const scope = commit.scope ? `**${commit.scope}:** ` : ''
|
||||||
text += `- ${ scope }${ commit.subject }\n`
|
text += `- ${scope}${commit.subject}\n`
|
||||||
})
|
})
|
||||||
|
|
||||||
return text
|
return text
|
||||||
@@ -28,8 +29,8 @@ module.exports = {
|
|||||||
|
|
||||||
renderChangelog: function (release, changes) {
|
renderChangelog: function (release, changes) {
|
||||||
const now = new Date()
|
const now = new Date()
|
||||||
const d = now.toISOString().substring(0, 10);
|
const d = now.toISOString().substring(0, 10)
|
||||||
const header = `# ${ release } - ${ d }\n`;
|
const header = `# ${release} - ${d}\n`
|
||||||
return header + changes + '\n\n'
|
return header + changes + '\n\n'
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
7
.github/workflows/changelog.yml
vendored
7
.github/workflows/changelog.yml
vendored
@@ -1,18 +1,19 @@
|
|||||||
|
---
|
||||||
name: Debug Changelog # Workflow name displayed on GitHub
|
name: Debug Changelog # Workflow name displayed on GitHub
|
||||||
on:
|
on:
|
||||||
workflow_dispatch: # Trigger manually
|
workflow_dispatch: # Trigger manually
|
||||||
jobs:
|
jobs:
|
||||||
debug-changelog:
|
debug-changelog:
|
||||||
runs-on: ubuntu-latest
|
runs-on: self-hosted
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
- name: Create changelog text
|
- name: Create changelog text
|
||||||
id: changelog
|
id: changelog
|
||||||
uses: loopwerk/tag-changelog@v1
|
uses: loopwerk/tag-changelog@v1
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
config_file: .github/tag-changelog-config.js
|
config_file: .github/tag-changelog-config.js
|
||||||
- name: "Echo results"
|
- name: 'Echo results'
|
||||||
id: output-changelog
|
id: output-changelog
|
||||||
run: |
|
run: |
|
||||||
echo "${{ steps.changelog.outputs.changes }}"
|
echo "${{ steps.changelog.outputs.changes }}"
|
||||||
|
|||||||
5
.github/workflows/linters.yml
vendored
5
.github/workflows/linters.yml
vendored
@@ -1,11 +1,12 @@
|
|||||||
|
---
|
||||||
name: reviewdog
|
name: reviewdog
|
||||||
on: [push]
|
on: [push]
|
||||||
jobs:
|
jobs:
|
||||||
linters:
|
linters:
|
||||||
name: Linters
|
name: Linters
|
||||||
runs-on: ubuntu-latest
|
runs-on: self-hosted
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
- name: GitHub Actions
|
- name: GitHub Actions
|
||||||
uses: reviewdog/action-actionlint@v1
|
uses: reviewdog/action-actionlint@v1
|
||||||
with:
|
with:
|
||||||
|
|||||||
18
.github/workflows/new-release.yml
vendored
18
.github/workflows/new-release.yml
vendored
@@ -1,21 +1,24 @@
|
|||||||
name: Release Daily State # Workflow name displayed on GitHub
|
---
|
||||||
|
name: Release Daily State
|
||||||
on:
|
on:
|
||||||
workflow_dispatch: # Trigger manually
|
workflow_dispatch:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: "30 20 * * *" # UTC is 2-3 hours behind Europe/Helsinki, my timezone
|
- cron: '0 21 * * *' # 00:00 at Europe/Helsinki
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
jobs:
|
jobs:
|
||||||
new-daily-release:
|
new-daily-release:
|
||||||
runs-on: ubuntu-latest
|
runs-on: self-hosted
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
outputs:
|
outputs:
|
||||||
created: ${{ steps.daily-version.outputs.created }}
|
created: ${{ steps.daily-version.outputs.created }}
|
||||||
version: ${{ steps.daily-version.outputs.version }}
|
version: ${{ steps.daily-version.outputs.version }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3 # Checkout our working repository
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Create tag if necessary
|
- name: Create tag if necessary
|
||||||
uses: fregante/daily-version-action@v2
|
uses: fregante/daily-version-action@v2
|
||||||
id: daily-version
|
id: daily-version
|
||||||
|
|
||||||
- name: Create changelog text
|
- name: Create changelog text
|
||||||
if: steps.daily-version.outputs.created
|
if: steps.daily-version.outputs.created
|
||||||
id: changelog
|
id: changelog
|
||||||
@@ -23,6 +26,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
config_file: .github/tag-changelog-config.js
|
config_file: .github/tag-changelog-config.js
|
||||||
|
|
||||||
- name: Create release
|
- name: Create release
|
||||||
if: steps.daily-version.outputs.created
|
if: steps.daily-version.outputs.created
|
||||||
uses: actions/create-release@latest
|
uses: actions/create-release@latest
|
||||||
|
|||||||
24
.github/workflows/pre-commit-autoupdate.yml
vendored
Normal file
24
.github/workflows/pre-commit-autoupdate.yml
vendored
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
---
|
||||||
|
name: Pre-commit autoupdate
|
||||||
|
on:
|
||||||
|
schedule:
|
||||||
|
# At 04:00 on Monday and Thursday.
|
||||||
|
- cron: "0 4 * * 1,4"
|
||||||
|
workflow_dispatch:
|
||||||
|
jobs:
|
||||||
|
auto-update:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
pull-requests: write
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- uses: actions/setup-python@v5.4.0
|
||||||
|
- run: pip install pre-commit && pre-commit autoupdate
|
||||||
|
- uses: peter-evans/create-pull-request@v7
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
branch: update/pre-commit-hooks
|
||||||
|
title: "chore: update pre-commit hooks"
|
||||||
|
commit-message: "chore: update pre-commit hooks"
|
||||||
|
body: Update versions of pre-commit hooks to latest version.
|
||||||
19
.github/workflows/semantic-pr.yml
vendored
Normal file
19
.github/workflows/semantic-pr.yml
vendored
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
---
|
||||||
|
name: Semantic PR
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request_target:
|
||||||
|
types:
|
||||||
|
- opened
|
||||||
|
- edited
|
||||||
|
- synchronize
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
semantic-pr:
|
||||||
|
runs-on: self-hosted
|
||||||
|
steps:
|
||||||
|
- uses: amannn/action-semantic-pull-request@v5.5.3
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
validateSingleCommit: true
|
||||||
23
.github/workflows/sync-labels.yml
vendored
Normal file
23
.github/workflows/sync-labels.yml
vendored
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
---
|
||||||
|
name: Sync labels
|
||||||
|
|
||||||
|
# yamllint disable-line rule:truthy
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths:
|
||||||
|
- .github/workflows/sync-labels.yml
|
||||||
|
- .github/labels.yml
|
||||||
|
schedule:
|
||||||
|
- cron: "34 5 * * *"
|
||||||
|
workflow_call:
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
SyncLabels:
|
||||||
|
permissions:
|
||||||
|
issues: write
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: ivuorinen/actions/sync-labels@main
|
||||||
17
.github/workflows/update-submodules.yml
vendored
17
.github/workflows/update-submodules.yml
vendored
@@ -1,17 +1,20 @@
|
|||||||
|
---
|
||||||
name: Update submodules
|
name: Update submodules
|
||||||
on:
|
on:
|
||||||
schedule: [{cron: 0 3 * * *}]
|
schedule:
|
||||||
|
# At 04:00 on Monday and Thursday.
|
||||||
|
- cron: "0 4 * * 1,4"
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
issues: write
|
|
||||||
pull-requests: write
|
|
||||||
jobs:
|
jobs:
|
||||||
update-submodules:
|
update-submodules:
|
||||||
runs-on: ubuntu-latest
|
permissions:
|
||||||
|
contents: write
|
||||||
|
issues: write
|
||||||
|
pull-requests: write
|
||||||
|
runs-on: self-hosted
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: true
|
submodules: true
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|||||||
29
.gitignore
vendored
29
.gitignore
vendored
@@ -1,16 +1,35 @@
|
|||||||
Brewfile.lock.json
|
!.gitkeep
|
||||||
*.log
|
|
||||||
*-secret
|
*-secret
|
||||||
|
*.bak
|
||||||
|
*.log
|
||||||
|
*.socket
|
||||||
*cache
|
*cache
|
||||||
|
.env
|
||||||
.idea
|
.idea
|
||||||
|
.nfs*
|
||||||
.vscode
|
.vscode
|
||||||
|
Brewfile.lock.json
|
||||||
|
antidote_plugins.zsh
|
||||||
|
config/alacritty/theme-active.toml
|
||||||
config/cheat/cheatsheets/pure-bash-bible/*
|
config/cheat/cheatsheets/pure-bash-bible/*
|
||||||
config/cheat/cheatsheets/tldr/*
|
config/cheat/cheatsheets/tldr/*
|
||||||
config/git/credentials
|
config/git/credentials
|
||||||
|
config/gnupg/S.*
|
||||||
|
config/gnupg/private-keys-v1.d
|
||||||
|
config/gnupg/s
|
||||||
|
config/iterm2/AppSupport
|
||||||
config/npm/npmrc
|
config/npm/npmrc
|
||||||
|
config/nvim/lazy-lock.json
|
||||||
|
config/nvim/spell/*
|
||||||
|
!config/nvim/spell/.gitkeep
|
||||||
|
config/zed/*
|
||||||
|
!config/zed/settings.json
|
||||||
config/zsh/.zcompdump
|
config/zsh/.zcompdump
|
||||||
|
iTermServer-*
|
||||||
|
lazy-lock.json
|
||||||
|
local/share/fonts/*
|
||||||
|
local/bin/asdf/plugins/*
|
||||||
|
lock
|
||||||
|
node_modules
|
||||||
ssh/local.d/*
|
ssh/local.d/*
|
||||||
!ssh/local.d/.gitkeep
|
!ssh/local.d/.gitkeep
|
||||||
!.gitkeep
|
|
||||||
.env
|
|
||||||
|
|
||||||
|
|||||||
91
.gitmodules
vendored
91
.gitmodules
vendored
@@ -1,4 +1,4 @@
|
|||||||
# vim: set expandtab:
|
# vim: noexpandtab filetype=gitconfig
|
||||||
[submodule "dotbot"]
|
[submodule "dotbot"]
|
||||||
path = tools/dotbot
|
path = tools/dotbot
|
||||||
url = https://github.com/anishathalye/dotbot.git
|
url = https://github.com/anishathalye/dotbot.git
|
||||||
@@ -19,46 +19,73 @@
|
|||||||
url = https://github.com/cheat/cheatsheets.git
|
url = https://github.com/cheat/cheatsheets.git
|
||||||
ignore = dirty
|
ignore = dirty
|
||||||
|
|
||||||
[submodule "tmux/tpm"]
|
|
||||||
path = config/tmux/plugins/tpm
|
|
||||||
url = https://github.com/tmux-plugins/tpm.git
|
|
||||||
ignore = dirty
|
|
||||||
[submodule "tmux/catppuccin"]
|
|
||||||
path = config/tmux/plugins/tmux
|
|
||||||
url = https://github.com/catppuccin/tmux.git
|
|
||||||
[submodule "tmux/tmux-1password"]
|
|
||||||
path = config/tmux/plugins/tmux-1password
|
|
||||||
url = https://github.com/yardnsm/tmux-1password.git
|
|
||||||
[submodule "tmux/tmux-autoreload"]
|
|
||||||
path = config/tmux/plugins/tmux-autoreload
|
|
||||||
url = https://github.com/b0o/tmux-autoreload.git
|
|
||||||
[submodule "tmux/tmux-continuum"]
|
[submodule "tmux/tmux-continuum"]
|
||||||
path = config/tmux/plugins/tmux-continuum
|
path = config/tmux/plugins/tmux-continuum
|
||||||
url = https://github.com/tmux-plugins/tmux-continuum
|
url = https://github.com/tmux-plugins/tmux-continuum
|
||||||
[submodule "tmux/tmux-fzf"]
|
ignore = dirty
|
||||||
path = config/tmux/plugins/tmux-fzf
|
|
||||||
url = https://github.com/sainnhe/tmux-fzf.git
|
|
||||||
[submodule "tmux/tmux-menus"]
|
|
||||||
path = config/tmux/plugins/tmux-menus
|
|
||||||
url = https://github.com/jaclu/tmux-menus.git
|
|
||||||
[submodule "tmux/tmux-notify"]
|
|
||||||
path = config/tmux/plugins/tmux-notify
|
|
||||||
url = https://github.com/ChanderG/tmux-notify.git
|
|
||||||
[submodule "tmux/tmux-resurrect"]
|
|
||||||
path = config/tmux/plugins/tmux-resurrect
|
|
||||||
url = https://github.com/tmux-plugins/tmux-resurrect
|
|
||||||
[submodule "tmux/tmux-sensible"]
|
[submodule "tmux/tmux-sensible"]
|
||||||
path = config/tmux/plugins/tmux-sensible
|
path = config/tmux/plugins/tmux-sensible
|
||||||
url = https://github.com/tmux-plugins/tmux-sensible.git
|
url = https://github.com/tmux-plugins/tmux-sensible.git
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
[submodule "tmux/tmux-sessionist"]
|
[submodule "tmux/tmux-sessionist"]
|
||||||
path = config/tmux/plugins/tmux-sessionist
|
path = config/tmux/plugins/tmux-sessionist
|
||||||
url = https://github.com/tmux-plugins/tmux-sessionist.git
|
url = https://github.com/tmux-plugins/tmux-sessionist.git
|
||||||
[submodule "tmux/tmux-suspend"]
|
ignore = dirty
|
||||||
path = config/tmux/plugins/tmux-suspend
|
|
||||||
url = https://github.com/MunifTanjim/tmux-suspend.git
|
|
||||||
[submodule "tmux/tmux-yank"]
|
[submodule "tmux/tmux-yank"]
|
||||||
path = config/tmux/plugins/tmux-yank
|
path = config/tmux/plugins/tmux-yank
|
||||||
url = https://github.com/tmux-plugins/tmux-yank.git
|
url = https://github.com/tmux-plugins/tmux-yank.git
|
||||||
[submodule "tmux/vim-tmux-navigator"]
|
ignore = dirty
|
||||||
path = config/tmux/plugins/vim-tmux-navigator
|
|
||||||
url = https://github.com/christoomey/vim-tmux-navigator.git
|
[submodule "tmux/tmux-window-name"]
|
||||||
|
path = config/tmux/plugins/tmux-window-name
|
||||||
|
url = https://github.com/ivuorinen/tmux-window-name.git
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
|
[submodule "dotbot-pip"]
|
||||||
|
path = tools/dotbot-pip
|
||||||
|
url = https://github.com/sobolevn/dotbot-pip.git
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
|
[submodule "tmux/tmux-suspend"]
|
||||||
|
path = config/tmux/plugins/tmux-suspend
|
||||||
|
url = https://github.com/MunifTanjim/tmux-suspend.git
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
|
[submodule "tmux/tmux-mode-indicator"]
|
||||||
|
path = config/tmux/plugins/tmux-mode-indicator
|
||||||
|
url = https://github.com/MunifTanjim/tmux-mode-indicator.git
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
|
[submodule "tmux/tmux-current-pane-hostname"]
|
||||||
|
path = config/tmux/plugins/tmux-current-pane-hostname
|
||||||
|
url = https://github.com/soyuka/tmux-current-pane-hostname.git
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
|
[submodule "cheat-tldr"]
|
||||||
|
path = config/cheat/cheatsheets/tldr
|
||||||
|
url = https://github.com/ivuorinen/cheatsheet-tldr.git
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
|
[submodule "tmux/tmux-dark-notify"]
|
||||||
|
path = config/tmux/plugins/tmux-dark-notify
|
||||||
|
url = https://github.com/erikw/tmux-dark-notify.git
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
|
[submodule "asdf"]
|
||||||
|
path = local/bin/asdf
|
||||||
|
url = https://github.com/asdf-vm/asdf.git
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
|
[submodule "antidote"]
|
||||||
|
path = tools/antidote
|
||||||
|
url = https://github.com/mattmc3/antidote.git
|
||||||
|
shallow = true
|
||||||
|
ignore = dirty
|
||||||
|
|
||||||
|
[submodule "dotbot-asdf"]
|
||||||
|
path = tools/dotbot-asdf
|
||||||
|
url = https://github.com/sobolevn/dotbot-asdf
|
||||||
|
ignore = dirty
|
||||||
|
|||||||
5
.ignore
5
.ignore
@@ -1,6 +1,7 @@
|
|||||||
.git/**
|
.git/**
|
||||||
config/cheat/cheatsheets/community/**
|
config/cheat/cheatsheets/community/**
|
||||||
tools/dotbot/**
|
node_modules
|
||||||
|
tools/antidote/**
|
||||||
tools/dotbot-brew/**
|
tools/dotbot-brew/**
|
||||||
tools/dotbot-include/**
|
tools/dotbot-include/**
|
||||||
|
tools/dotbot/**
|
||||||
|
|||||||
5
.luarc.json
Normal file
5
.luarc.json
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
"diagnostics.globals": [
|
||||||
|
"vim"
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"extends": "markdownlint/style/prettier",
|
"extends": "@ivuorinen/markdownlint-config",
|
||||||
"code-block-style": {
|
"code-block-style": {
|
||||||
"style": "fenced"
|
"style": "fenced"
|
||||||
},
|
},
|
||||||
|
|||||||
8
.markdownlintignore
Normal file
8
.markdownlintignore
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
# only care about files that are directly under our control
|
||||||
|
config/cheat/cheatsheets/community/*
|
||||||
|
config/cheat/cheatsheets/tldr/*
|
||||||
|
config/tmux/plugins/*
|
||||||
|
local/bin/asdf/*
|
||||||
|
tools/*
|
||||||
|
node_modules/*
|
||||||
|
|
||||||
59
.pre-commit-config.yaml
Normal file
59
.pre-commit-config.yaml
Normal file
@@ -0,0 +1,59 @@
|
|||||||
|
repos:
|
||||||
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||||
|
rev: v5.0.0
|
||||||
|
hooks:
|
||||||
|
- id: requirements-txt-fixer
|
||||||
|
- id: detect-aws-credentials
|
||||||
|
- id: detect-private-key
|
||||||
|
- id: trailing-whitespace
|
||||||
|
args: [--markdown-linebreak-ext=md]
|
||||||
|
- id: check-case-conflict
|
||||||
|
- id: check-merge-conflict
|
||||||
|
- id: check-executables-have-shebangs
|
||||||
|
- id: check-shebang-scripts-are-executable
|
||||||
|
- id: check-symlinks
|
||||||
|
- id: check-toml
|
||||||
|
- id: check-xml
|
||||||
|
- id: check-yaml
|
||||||
|
args: [--allow-multiple-documents]
|
||||||
|
- id: end-of-file-fixer
|
||||||
|
- id: mixed-line-ending
|
||||||
|
args: [--fix=auto]
|
||||||
|
- id: pretty-format-json
|
||||||
|
args: [--autofix, --no-sort-keys]
|
||||||
|
|
||||||
|
- repo: https://github.com/igorshubovych/markdownlint-cli
|
||||||
|
rev: v0.44.0
|
||||||
|
hooks:
|
||||||
|
- id: markdownlint
|
||||||
|
args: [-c, .markdownlint.json, --fix]
|
||||||
|
|
||||||
|
- repo: https://github.com/adrienverge/yamllint
|
||||||
|
rev: v1.35.1
|
||||||
|
hooks:
|
||||||
|
- id: yamllint
|
||||||
|
|
||||||
|
- repo: https://github.com/koalaman/shellcheck-precommit
|
||||||
|
rev: v0.10.0
|
||||||
|
hooks:
|
||||||
|
- id: shellcheck
|
||||||
|
|
||||||
|
- repo: https://github.com/scop/pre-commit-shfmt
|
||||||
|
rev: v3.10.0-2
|
||||||
|
hooks:
|
||||||
|
- id: shfmt
|
||||||
|
|
||||||
|
- repo: https://github.com/rhysd/actionlint
|
||||||
|
rev: v1.7.7
|
||||||
|
hooks:
|
||||||
|
- id: actionlint
|
||||||
|
|
||||||
|
- repo: https://github.com/renovatebot/pre-commit-hooks
|
||||||
|
rev: 39.161.4
|
||||||
|
hooks:
|
||||||
|
- id: renovate-config-validator
|
||||||
|
|
||||||
|
- repo: https://github.com/JohnnyMorganz/StyLua
|
||||||
|
rev: v2.0.2
|
||||||
|
hooks:
|
||||||
|
- id: stylua # or stylua-system / stylua-github
|
||||||
14
.prettierignore
Normal file
14
.prettierignore
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
# vim: ft=gitignore
|
||||||
|
.mypy_cache/*
|
||||||
|
Brewfile.lock.json
|
||||||
|
config/cheat/cheatsheets/community
|
||||||
|
config/cheat/cheatsheets/tldr
|
||||||
|
config/fzf/*
|
||||||
|
config/nvim/*
|
||||||
|
config/tmux/plugins/*
|
||||||
|
config/zsh/*
|
||||||
|
lazy-lock.json
|
||||||
|
local/bin/antigen.zsh
|
||||||
|
local/bin/asdf
|
||||||
|
tools/antidote/*
|
||||||
|
tools/dotbot*
|
||||||
14
.prettierrc.js
Normal file
14
.prettierrc.js
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
module.exports = {
|
||||||
|
...require('@ivuorinen/prettier-config'),
|
||||||
|
trailingComma: 'all',
|
||||||
|
// Add custom options below:
|
||||||
|
overrides: [
|
||||||
|
{
|
||||||
|
files: '*.md',
|
||||||
|
options: {
|
||||||
|
printWidth: 120,
|
||||||
|
proseWrap: 'preserve',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
}
|
||||||
@@ -1 +1 @@
|
|||||||
3.11
|
3.13.2
|
||||||
|
|||||||
3
.releaserc.json
Normal file
3
.releaserc.json
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"extends": ["@ivuorinen/semantic-release-config"]
|
||||||
|
}
|
||||||
@@ -5,3 +5,26 @@
|
|||||||
external-sources=true
|
external-sources=true
|
||||||
includeAllWorkspaceSymbols=true
|
includeAllWorkspaceSymbols=true
|
||||||
|
|
||||||
|
# SC2039: In POSIX sh, 'local' is undefined.
|
||||||
|
# https://github.com/koalaman/shellcheck/wiki/SC2039
|
||||||
|
disable=SC2039
|
||||||
|
|
||||||
|
# SC2166: Prefer [ p ] || [ q ] as [ p -o q ] is not well defined.
|
||||||
|
# https://github.com/koalaman/shellcheck/wiki/SC2166
|
||||||
|
disable=SC2166
|
||||||
|
|
||||||
|
# SC2154: Variable is referenced but not assigned
|
||||||
|
# https://github.com/koalaman/shellcheck/wiki/SC2154
|
||||||
|
disable=SC2154
|
||||||
|
|
||||||
|
# SC1091: Not following <file>
|
||||||
|
# https://github.com/koalaman/shellcheck/wiki/SC1091
|
||||||
|
disable=SC1091
|
||||||
|
|
||||||
|
# SC2174: When used with -p, -m only applies to the deepest directory.
|
||||||
|
# https://github.com/koalaman/shellcheck/wiki/SC2174
|
||||||
|
disable=SC2174
|
||||||
|
|
||||||
|
# SC2016: Expressions don't expand in single quotes, use double quotes for that.
|
||||||
|
# https://www.shellcheck.net/wiki/SC2016
|
||||||
|
disable=SC2016
|
||||||
|
|||||||
24
.yamlfmt
24
.yamlfmt
@@ -1,24 +0,0 @@
|
|||||||
formatter:
|
|
||||||
type: basic
|
|
||||||
indent: 2
|
|
||||||
retain_line_breaks: false
|
|
||||||
disallow_anchors: false
|
|
||||||
max_line_length: 0
|
|
||||||
scan_folded_as_literal: false
|
|
||||||
indentless_arrays: false
|
|
||||||
|
|
||||||
doublestar: true
|
|
||||||
|
|
||||||
extensions:
|
|
||||||
- yaml
|
|
||||||
- yml
|
|
||||||
|
|
||||||
include:
|
|
||||||
- ./*.{yml,yaml}
|
|
||||||
- ./**/*.{yml,yaml}
|
|
||||||
|
|
||||||
exclude:
|
|
||||||
- ./tools/dotbot/**
|
|
||||||
- ./tools/dotbot-*/**
|
|
||||||
- ./config/astronvim/**
|
|
||||||
- ./config/nvim/**
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
# .yamlignore
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,36 +1,62 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
git submodule add --name dotbot -f https://github.com/anishathalye/dotbot.git tools/dotbot
|
# dotbot and plugins
|
||||||
git submodule add --name dotbot-brew -f https://github.com/wren/dotbot-brew.git tools/dotbot-brew
|
git submodule add --name dotbot \
|
||||||
git submodule add --name dotbot-include -f https://gitlab.com/gnfzdz/dotbot-include.git tools/dotbot-include
|
-f https://github.com/anishathalye/dotbot.git tools/dotbot
|
||||||
git submodule add --name cheat-community -f https://github.com/cheat/cheatsheets.git config/cheat/cheatsheets/community
|
git submodule add --name dotbot-brew \
|
||||||
|
-f https://github.com/wren/dotbot-brew.git tools/dotbot-brew
|
||||||
|
git submodule add --name dotbot-include \
|
||||||
|
-f https://gitlab.com/gnfzdz/dotbot-include.git tools/dotbot-include
|
||||||
|
git submodule add --name dotbot-pip \
|
||||||
|
-f https://github.com/sobolevn/dotbot-pip.git tools/dotbot-pip
|
||||||
|
git submodule add --name dotbot-asdf \
|
||||||
|
-f https://github.com/sobolevn/dotbot-asdf tools/dotbot-asdf
|
||||||
|
|
||||||
|
# other repos
|
||||||
|
git submodule add --name cheat-community \
|
||||||
|
-f https://github.com/cheat/cheatsheets.git config/cheat/cheatsheets/community
|
||||||
|
git submodule add --name cheat-tldr \
|
||||||
|
-f https://github.com/ivuorinen/cheatsheet-tldr.git config/cheat/cheatsheets/tldr
|
||||||
|
git submodule add --name asdf \
|
||||||
|
-f https://github.com/asdf-vm/asdf.git local/bin/asdf
|
||||||
|
git submodule add --name antidote \
|
||||||
|
--depth 1 \
|
||||||
|
-f https://github.com/mattmc3/antidote.git tools/antidote
|
||||||
|
|
||||||
# tmux plugin manager and plugins
|
# tmux plugin manager and plugins
|
||||||
git submodule add --name tmux/tpm \
|
|
||||||
-f https://github.com/tmux-plugins/tpm.git config/tmux/plugins/tpm
|
|
||||||
git submodule add --name tmux/catppuccin \
|
|
||||||
-f https://github.com/catppuccin/tmux.git config/tmux/plugins/tmux
|
|
||||||
git submodule add --name tmux/tmux-1password \
|
|
||||||
-f https://github.com/yardnsm/tmux-1password.git config/tmux/plugins/tmux-1password
|
|
||||||
git submodule add --name tmux/tmux-autoreload \
|
|
||||||
-f https://github.com/b0o/tmux-autoreload.git config/tmux/plugins/tmux-autoreload
|
|
||||||
git submodule add --name tmux/tmux-continuum \
|
git submodule add --name tmux/tmux-continuum \
|
||||||
-f https://github.com/tmux-plugins/tmux-continuum config/tmux/plugins/tmux-continuum
|
-f https://github.com/tmux-plugins/tmux-continuum config/tmux/plugins/tmux-continuum
|
||||||
git submodule add --name tmux/tmux-fzf \
|
git submodule add --name tmux/tmux-mode-indicator \
|
||||||
-f https://github.com/sainnhe/tmux-fzf.git config/tmux/plugins/tmux-fzf
|
-f https://github.com/MunifTanjim/tmux-mode-indicator.git config/tmux/plugins/tmux-mode-indicator
|
||||||
git submodule add --name tmux/tmux-menus \
|
|
||||||
-f https://github.com/jaclu/tmux-menus.git config/tmux/plugins/tmux-menus
|
|
||||||
git submodule add --name tmux/tmux-notify \
|
|
||||||
-f https://github.com/ChanderG/tmux-notify.git config/tmux/plugins/tmux-notify
|
|
||||||
git submodule add --name tmux/tmux-resurrect \
|
|
||||||
-f https://github.com/tmux-plugins/tmux-resurrect config/tmux/plugins/tmux-resurrect
|
|
||||||
git submodule add --name tmux/tmux-sensible \
|
git submodule add --name tmux/tmux-sensible \
|
||||||
-f https://github.com/tmux-plugins/tmux-sensible.git config/tmux/plugins/tmux-sensible
|
-f https://github.com/tmux-plugins/tmux-sensible.git config/tmux/plugins/tmux-sensible
|
||||||
git submodule add --name tmux/tmux-sessionist \
|
git submodule add --name tmux/tmux-sessionist \
|
||||||
-f https://github.com/tmux-plugins/tmux-sessionist.git config/tmux/plugins/tmux-sessionist
|
-f https://github.com/tmux-plugins/tmux-sessionist.git config/tmux/plugins/tmux-sessionist
|
||||||
git submodule add --name tmux/tmux-suspend \
|
git submodule add --name tmux/tmux-suspend \
|
||||||
-f https://github.com/MunifTanjim/tmux-suspend.git config/tmux/plugins/tmux-suspend
|
-f https://github.com/MunifTanjim/tmux-suspend.git config/tmux/plugins/tmux-suspend
|
||||||
|
git submodule add --name tmux/tmux-window-name \
|
||||||
|
-f https://github.com/ivuorinen/tmux-window-name.git config/tmux/plugins/tmux-window-name
|
||||||
git submodule add --name tmux/tmux-yank \
|
git submodule add --name tmux/tmux-yank \
|
||||||
-f https://github.com/tmux-plugins/tmux-yank.git config/tmux/plugins/tmux-yank
|
-f https://github.com/tmux-plugins/tmux-yank.git config/tmux/plugins/tmux-yank
|
||||||
git submodule add --name tmux/vim-tmux-navigator \
|
git submodule add --name tmux/tmux-current-pane-hostname \
|
||||||
-f https://github.com/christoomey/vim-tmux-navigator.git config/tmux/plugins/vim-tmux-navigator
|
-f https://github.com/soyuka/tmux-current-pane-hostname.git config/tmux/plugins/tmux-current-pane-hostname
|
||||||
|
git submodule add --name tmux/tmux-dark-notify \
|
||||||
|
-f https://github.com/erikw/tmux-dark-notify.git config/tmux/plugins/tmux-dark-notify
|
||||||
|
|
||||||
|
# Takes submodules and sets them to ignore all changes
|
||||||
|
for MODULE in $(git config --file .gitmodules --get-regexp path | awk '{ print $2 }'); do
|
||||||
|
echo "Ignoring submodule changes for submodule.${MODULE}..."
|
||||||
|
git config "submodule.${MODULE}.ignore" "dirty"
|
||||||
|
done
|
||||||
|
|
||||||
|
# Mark certain repositories shallow
|
||||||
|
git config -f .gitmodules submodule.antidote.shallow true
|
||||||
|
|
||||||
|
# remove old submodules
|
||||||
|
[ -d "config/tmux/plugins/tpm" ] && rm -rf config/tmux/plugins/tpm
|
||||||
|
[ -d "config/tmux/plugins/tmux" ] && rm -rf config/tmux/plugins/tmux
|
||||||
|
[ -d "config/tmux/plugins/tmux-menus" ] && rm -rf config/tmux/plugins/tmux-menus
|
||||||
|
[ -d "config/tmux/plugins/tmux-resurrect" ] && rm -rf config/tmux/plugins/tmux-resurrect
|
||||||
|
[ -d "tools/dotbot-crontab" ] && rm -rf tools/dotbot-crontab
|
||||||
|
[ -d "tools/dotbot-snap" ] && rm -rf tools/dotbot-snap
|
||||||
|
[ -d "config/nvim-kickstart" ] && rm -rf config/nvim-kickstart
|
||||||
|
|||||||
37
base/bashrc
37
base/bashrc
@@ -1,26 +1,27 @@
|
|||||||
# this is my bashrc config. there are many like it, but this one is mine.
|
# this is my bashrc config. there are many like it, but this one is mine.
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
# Defaults
|
|
||||||
export DOTFILES="$HOME/.dotfiles"
|
export DOTFILES="$HOME/.dotfiles"
|
||||||
|
export PATH="$HOME/.local/bin:$DOTFILES/local/bin:$PATH"
|
||||||
|
export SHARED_SCRIPTS_SOURCED=0
|
||||||
|
|
||||||
# Run x-load-configs in your terminal to reload the files.
|
source "$DOTFILES/config/shared.sh"
|
||||||
function x-load-configs()
|
|
||||||
{
|
|
||||||
HOST="$(hostname -s)"
|
|
||||||
# Load the shell dotfiles, and then some:
|
|
||||||
for file in $DOTFILES/config/{exports,alias,functions}; do
|
|
||||||
[ -r "$file" ] && source "$file"
|
|
||||||
[ -r "$file-secret" ] && source "$file-secret"
|
|
||||||
[ -r "$file-$HOST" ] && source "$file-$HOST"
|
|
||||||
[ -r "$file-$HOST-secret" ] && source "$file-$HOST-secret"
|
|
||||||
done
|
|
||||||
}
|
|
||||||
x-load-configs
|
|
||||||
|
|
||||||
# Import ssh keys in keychain
|
if [ -n "${GHOSTTY_RESOURCES_DIR}" ]; then
|
||||||
ssh-add -A 2>/dev/null;
|
builtin source "${GHOSTTY_RESOURCES_DIR}/shell-integration/bash/ghostty.bash"
|
||||||
|
fi
|
||||||
|
|
||||||
# shellcheck source=../config/fzf/fzf.bash
|
# shellcheck source=../config/fzf/fzf.bash
|
||||||
[ -f "${DOTFILES}/config/fzf/fzf.bash" ] \
|
[ -f "${DOTFILES}/config/fzf/fzf.bash" ] &&
|
||||||
&& source "${DOTFILES}/config/fzf/fzf.bash"
|
source "${DOTFILES}/config/fzf/fzf.bash"
|
||||||
|
|
||||||
|
# Import ssh keys in keychain
|
||||||
|
ssh-add -A 2>/dev/null
|
||||||
|
|
||||||
|
x-have antidot && {
|
||||||
|
eval "$(antidot init)"
|
||||||
|
}
|
||||||
|
|
||||||
|
PROMPT_DIRTRIM=3
|
||||||
|
PROMPT_COMMAND='PS1_CMD1=$(git branch --show-current 2>/dev/null)'
|
||||||
|
PS1='\[\e[95m\]\u\[\e[0m\]@\[\e[38;5;22;2m\]\h\[\e[0m\] \[\e[38;5;33m\]\w\[\e[0m\] \[\e[92;2m\]${PS1_CMD1}\n\[\e[39m\]➜\[\e[0m\] '
|
||||||
|
|||||||
2
base/envrc
Normal file
2
base/envrc
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
use node
|
||||||
|
use asdf
|
||||||
@@ -1,6 +1,4 @@
|
|||||||
#!/bin/env bash
|
#!/bin/env bash
|
||||||
|
|
||||||
export NVM_DIR="$HOME/.nvm"
|
[ -z "$NVM_DIR" ] && export NVM_DIR="$HOME/.config/nvm"
|
||||||
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
|
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
|
||||||
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
|
||||||
|
|
||||||
|
|||||||
6
base/ignore
Normal file
6
base/ignore
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
Applications/
|
||||||
|
Library/
|
||||||
|
Movies/
|
||||||
|
Music/
|
||||||
|
Pictures/
|
||||||
|
Google Drive/
|
||||||
1
base/nvmrc
Normal file
1
base/nvmrc
Normal file
@@ -0,0 +1 @@
|
|||||||
|
lts/*
|
||||||
19
base/tool-versions
Normal file
19
base/tool-versions
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
golang 1.23.4
|
||||||
|
rust 1.83.0
|
||||||
|
direnv 2.35.0
|
||||||
|
fd 10.2.0
|
||||||
|
1password-cli 2.30.3
|
||||||
|
age 1.2.1
|
||||||
|
dotenv-linter 3.3.0
|
||||||
|
editorconfig-checker 2.8.0
|
||||||
|
github-cli 2.64.0
|
||||||
|
hadolint 2.12.0
|
||||||
|
kubectl 1.32.0
|
||||||
|
pre-commit 4.0.1
|
||||||
|
ripgrep 14.1.1
|
||||||
|
shellcheck 0.10.0
|
||||||
|
shfmt 3.10.0
|
||||||
|
terragrunt 0.71.1
|
||||||
|
tf-summarize 0.3.14
|
||||||
|
yamllint 1.35.1
|
||||||
|
yq 4.44.6
|
||||||
24
base/vuerc
24
base/vuerc
@@ -1,24 +0,0 @@
|
|||||||
{
|
|
||||||
"useTaobaoRegistry": false,
|
|
||||||
"presets": {
|
|
||||||
"v2-router-vuex-scss-prettier": {
|
|
||||||
"useConfigFiles": false,
|
|
||||||
"plugins": {
|
|
||||||
"@vue/cli-plugin-babel": {},
|
|
||||||
"@vue/cli-plugin-router": {
|
|
||||||
"historyMode": false
|
|
||||||
},
|
|
||||||
"@vue/cli-plugin-vuex": {},
|
|
||||||
"@vue/cli-plugin-eslint": {
|
|
||||||
"config": "prettier",
|
|
||||||
"lintOn": [
|
|
||||||
"save"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"vueVersion": "2",
|
|
||||||
"cssPreprocessor": "dart-sass"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
108
base/zshrc
108
base/zshrc
@@ -1,76 +1,62 @@
|
|||||||
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
|
|
||||||
# Initialization code that may require console input (password prompts, [y/n]
|
|
||||||
# confirmations, etc.) must go above this block; everything else may go below.
|
|
||||||
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
|
|
||||||
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# this is my zsh config. there are many like it, but this one is mine.
|
# this is my zsh config. there are many like it, but this one is mine.
|
||||||
|
# https://zsh.sourceforge.io/Intro/intro_3.html
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
# Defaults
|
# export VERBOSE=1
|
||||||
|
# export DEBUG=1
|
||||||
|
autoload -U promptinit; promptinit
|
||||||
|
|
||||||
export DOTFILES="$HOME/.dotfiles"
|
export DOTFILES="$HOME/.dotfiles"
|
||||||
# shellcheck source=scripts/shared.sh
|
LOCAL_SHARE="$HOME/.local/share"
|
||||||
source "$DOTFILES/scripts/shared.sh"
|
export PATH="$HOME/.local/bin:$DOTFILES/local/bin:$LOCAL_SHARE/nvim/mason/bin:$LOCAL_SHARE/bob/nvim-bin:$LOCAL_SHARE/cargo/bin:/opt/homebrew/bin:/usr/local/bin:$PATH"
|
||||||
|
export SHARED_SCRIPTS_SOURCED=0
|
||||||
|
|
||||||
export COMPLETION_WAITING_DOTS=true
|
source "$DOTFILES/config/shared.sh"
|
||||||
|
source "${XDG_CONFIG_HOME:-$HOME/.config}/asdf-direnv/zshrc"
|
||||||
|
|
||||||
# Run x-load-configs in your terminal to reload the files.
|
ZSH_COMPDUMP="$XDG_CACHE_HOME/zsh/zcompdump-${SHORT_HOST}-${ZSH_VERSION}"
|
||||||
function x-load-configs()
|
|
||||||
|
source "$DOTFILES/config/zsh/antidote.zsh"
|
||||||
|
# source "$DOTFILES/config/zsh/prompt.zsh"
|
||||||
|
|
||||||
|
# Function to source FZF configuration
|
||||||
|
source_fzf_config()
|
||||||
{
|
{
|
||||||
# Load the shell dotfiles, and then some:
|
local fzf_config="${DOTFILES}/config/fzf/fzf.zsh"
|
||||||
for file in $DOTFILES/config/{exports,alias,functions}; do
|
if [[ -f "$fzf_config" ]]; then
|
||||||
[ -r "$file" ] && source "$file"
|
# shellcheck source=config/fzf/fzf.zsh
|
||||||
[ -r "$file-secret" ] && source "$file-secret"
|
source "$fzf_config"
|
||||||
[ -r "$file-$HOSTNAME" ] && source "$file-$HOSTNAME"
|
fi
|
||||||
[ -r "$file-$HOSTNAME-secret" ] && source "$file-$HOSTNAME-secret"
|
|
||||||
done
|
|
||||||
}
|
}
|
||||||
x-load-configs
|
|
||||||
|
|
||||||
export HISTFILE="$XDG_STATE_HOME"/zsh/history
|
# Function to set up tmux window name plugin if tmux is active
|
||||||
|
setup_tmux_window_name_plugin()
|
||||||
|
{
|
||||||
|
if [[ -n "$TMUX" ]]; then
|
||||||
|
local tmux_window_name_plugin="$TMUX_PLUGINS/tmux-window-name/scripts/rename_session_windows.py"
|
||||||
|
if [[ -f "$tmux_window_name_plugin" ]]; then
|
||||||
|
tmux_window_name()
|
||||||
|
{
|
||||||
|
($tmux_window_name_plugin &)
|
||||||
|
}
|
||||||
|
add-zsh-hook chpwd tmux_window_name
|
||||||
|
tmux_window_name
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
autoload -U colors zsh/terminfo
|
if [[ -n $GHOSTTY_RESOURCES_DIR ]]; then
|
||||||
colors
|
source "$GHOSTTY_RESOURCES_DIR"/shell-integration/zsh/ghostty-integration
|
||||||
setopt correct
|
|
||||||
|
|
||||||
export ZSH_CUSTOM_COMPLETION_PATH="$XDG_CONFIG_HOME/zsh/completion"
|
|
||||||
x-dc "$ZSH_CUSTOM_COMPLETION_PATH"
|
|
||||||
|
|
||||||
# Add completion scripts to zsh path
|
|
||||||
FPATH="$ZSH_CUSTOM_COMPLETION_PATH:$FPATH"
|
|
||||||
autoload -Uz compinit
|
|
||||||
|
|
||||||
if type brew &>/dev/null
|
|
||||||
then
|
|
||||||
FPATH="$(brew --prefix)/share/zsh/site-functions:${FPATH}"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
compinit -d "$XDG_CACHE_HOME"/zsh/zcompdump-"$ZSH_VERSION"
|
source_fzf_config
|
||||||
|
setup_tmux_window_name_plugin
|
||||||
|
x-have antidot && eval "$(antidot init)"
|
||||||
|
|
||||||
# Import ssh keys in keychain
|
autoload -Uz compinit bashcompinit
|
||||||
ssh-add -A 2>/dev/null;
|
compinit -d $ZSH_COMPDUMP
|
||||||
|
bashcompinit
|
||||||
# Try to load antigen, if present
|
|
||||||
ANTIGEN_ZSH_PATH="$XDG_BIN_HOME/antigen.zsh"
|
|
||||||
[[ -f "$ANTIGEN_ZSH_PATH" ]] && source "$ANTIGEN_ZSH_PATH"
|
|
||||||
|
|
||||||
# antigen is present
|
|
||||||
have antigen && {
|
|
||||||
antigen use oh-my-zsh
|
|
||||||
|
|
||||||
# config/functions
|
|
||||||
x-default-antigen-bundles
|
|
||||||
|
|
||||||
antigen apply
|
|
||||||
}
|
|
||||||
|
|
||||||
# shellcheck source=../config/fzf/fzf.zsh
|
|
||||||
[ -f "${DOTFILES}/config/fzf/fzf.zsh" ] \
|
|
||||||
&& source "${DOTFILES}/config/fzf/fzf.zsh"
|
|
||||||
|
|
||||||
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
|
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
|
||||||
# shellcheck source=config/zsh/p10k.zsh
|
export P10K_CONFIG="$DOTFILES/config/zsh/p10k.zsh"
|
||||||
export P10K_LOCATION="$XDG_CONFIG_HOME/zsh/p10k.zsh"
|
[[ ! -f "$P10K_CONFIG" ]] || source "$P10K_CONFIG"
|
||||||
[[ ! -f $P10K_LOCATION ]] || source "$P10K_LOCATION"
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
--container-architecture linux/amd64
|
||||||
-P ubuntu-latest=catthehacker/ubuntu:act-latest
|
-P ubuntu-latest=catthehacker/ubuntu:act-latest
|
||||||
-P ubuntu-22.04=catthehacker/ubuntu:act-22.04
|
-P ubuntu-22.04=catthehacker/ubuntu:act-22.04
|
||||||
-P ubuntu-20.04=catthehacker/ubuntu:act-20.04
|
-P ubuntu-20.04=catthehacker/ubuntu:act-20.04
|
||||||
|
|||||||
244
config/aerospace/aerospace.toml
Normal file
244
config/aerospace/aerospace.toml
Normal file
@@ -0,0 +1,244 @@
|
|||||||
|
# Start AeroSpace at login
|
||||||
|
start-at-login = false
|
||||||
|
|
||||||
|
# Normalizations. See: https://nikitabobko.github.io/AeroSpace/guide#normalization
|
||||||
|
enable-normalization-flatten-containers = true
|
||||||
|
enable-normalization-opposite-orientation-for-nested-containers = true
|
||||||
|
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/guide#layouts
|
||||||
|
# The 'accordion-padding' specifies the size of accordion padding
|
||||||
|
# You can set 0 to disable the padding feature
|
||||||
|
accordion-padding = 10
|
||||||
|
|
||||||
|
# Possible values: tiles|accordion
|
||||||
|
default-root-container-layout = 'tiles'
|
||||||
|
|
||||||
|
# Possible values: horizontal|vertical|auto
|
||||||
|
# 'auto' means: wide monitor (anything wider than high) gets horizontal orientation,
|
||||||
|
# tall monitor (anything higher than wide) gets vertical orientation
|
||||||
|
default-root-container-orientation = 'auto'
|
||||||
|
|
||||||
|
# Mouse follows focus when focused monitor changes
|
||||||
|
# Drop it from your config, if you don't like this behavior
|
||||||
|
# See https://nikitabobko.github.io/AeroSpace/guide#on-focus-changed-callbacks
|
||||||
|
# See https://nikitabobko.github.io/AeroSpace/commands#move-mouse
|
||||||
|
# Fallback value (if you omit the key): on-focused-monitor-changed = []
|
||||||
|
on-focused-monitor-changed = ['move-mouse monitor-lazy-center']
|
||||||
|
|
||||||
|
# You can effectively turn off macOS "Hide application" (cmd-h) feature by toggling this flag
|
||||||
|
# Useful if you don't use this macOS feature, but accidentally hit cmd-h or cmd-alt-h key
|
||||||
|
# Also see: https://nikitabobko.github.io/AeroSpace/goodness#disable-hide-app
|
||||||
|
automatically-unhide-macos-hidden-apps = true
|
||||||
|
|
||||||
|
# [[on-window-detected]]
|
||||||
|
# if.app-id = 'com.apple.systempreferences'
|
||||||
|
# if.app-name-regex-substring = 'settings'
|
||||||
|
# if.window-title-regex-substring = 'substring'
|
||||||
|
# if.workspace = 'workspace-name'
|
||||||
|
# if.during-aerospace-startup = true
|
||||||
|
# check-further-callbacks = true
|
||||||
|
# run = ['layout floating', 'move-node-to-workspace S'] # The callback itself
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-name-regex-substring = 'settings' # All settings
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.apple.systempreferences' # macOS System Preferences
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.1password.1password' # 1Password
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'org.ferdium.ferdium-app' # Ferdium, has WhatsApp etc.
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.jetbrains.PhpStorm' # PhpStorm
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.apple.finder' # Finder
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.apple.Preview' # Preview
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.apple.mail' # Mail
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.DanPristupov.Fork' # Fork
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.flexibits.fantastical2.mac' # Fantastical
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'org.whispersystems.signal-desktop' # Signal
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.tidal.desktop' # TIDAL
|
||||||
|
run = ['layout floating', 'move-node-to-workspace 2'] # Float and move to workspace 2
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.apple.TV' # Apple TV app
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.setapp.DesktopClient' # Setapp
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.electron.dockerdesktop' # Docker Desktop
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.tinyspeck.slackmacgap' # Slack
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'md.obsidia' # Obsidian
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.todoist.mac.Todoist' # Todoist
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
[[on-window-detected]]
|
||||||
|
if.app-id = 'com.apple.backup.launcher' # TimeMachine
|
||||||
|
run = ['layout floating']
|
||||||
|
|
||||||
|
|
||||||
|
# Possible values: (qwerty|dvorak)
|
||||||
|
# See https://nikitabobko.github.io/AeroSpace/guide#key-mapping
|
||||||
|
[key-mapping]
|
||||||
|
preset = 'qwerty'
|
||||||
|
|
||||||
|
# Gaps between windows (inner-*) and between monitor edges (outer-*).
|
||||||
|
# Possible values:
|
||||||
|
# - Constant: gaps.outer.top = 8
|
||||||
|
# - Per monitor: gaps.outer.top = [{ monitor.main = 16 }, { monitor."some-pattern" = 32 }, 24]
|
||||||
|
# In this example, 24 is a default value when there is no match.
|
||||||
|
# Monitor pattern is the same as for 'workspace-to-monitor-force-assignment'.
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/guide#assign-workspaces-to-monitors
|
||||||
|
[gaps]
|
||||||
|
inner.horizontal = 5
|
||||||
|
inner.vertical = 5
|
||||||
|
outer.top = [{ monitor.'^built-in retina display$' = 0 }, 0]
|
||||||
|
outer.right = 0
|
||||||
|
outer.bottom = 0
|
||||||
|
outer.left = 0
|
||||||
|
|
||||||
|
# 'main' binding mode declaration
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/guide#binding-modes
|
||||||
|
# 'main' binding mode must be always presented
|
||||||
|
# Fallback value (if you omit the key): mode.main.binding = {}
|
||||||
|
[mode.main.binding]
|
||||||
|
|
||||||
|
cmd-h = [] # Disable "hide application"
|
||||||
|
cmd-alt-h = [] # Disable "hide others"
|
||||||
|
|
||||||
|
# All possible keys:
|
||||||
|
# - Letters. a, b, c, ..., z
|
||||||
|
# - Numbers. 0, 1, 2, ..., 9
|
||||||
|
# - Keypad numbers. keypad0, keypad1, keypad2, ..., keypad9
|
||||||
|
# - F-keys. f1, f2, ..., f20
|
||||||
|
# - Special keys. minus, equal, period, comma, slash, backslash, quote, semicolon, backtick,
|
||||||
|
# leftSquareBracket, rightSquareBracket, space, enter, esc, backspace, tab
|
||||||
|
# - Keypad special. keypadClear, keypadDecimalMark, keypadDivide, keypadEnter, keypadEqual,
|
||||||
|
# keypadMinus, keypadMultiply, keypadPlus
|
||||||
|
# - Arrows. left, down, up, right
|
||||||
|
|
||||||
|
# All possible modifiers: cmd, alt, ctrl, shift
|
||||||
|
|
||||||
|
# All possible commands: https://nikitabobko.github.io/AeroSpace/commands
|
||||||
|
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/commands#exec-and-forget
|
||||||
|
# You can uncomment the following lines to open up terminal with alt + enter shortcut (like in i3)
|
||||||
|
# alt-enter = '''exec-and-forget osascript -e '
|
||||||
|
# tell application "Terminal"
|
||||||
|
# do script
|
||||||
|
# activate
|
||||||
|
# end tell'
|
||||||
|
# '''
|
||||||
|
|
||||||
|
# alt-cmd-shift-f = 'fullscreen'
|
||||||
|
# alt-shift-f = 'layout floating'
|
||||||
|
# alt-shift-tab = 'move-workspace-to-monitor --wrap-around next'
|
||||||
|
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/commands#focus
|
||||||
|
alt-h = 'focus left'
|
||||||
|
alt-j = 'focus down'
|
||||||
|
alt-k = 'focus up'
|
||||||
|
alt-l = 'focus right'
|
||||||
|
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/commands#workspace
|
||||||
|
alt-shift-1 = 'workspace 1' # Main
|
||||||
|
alt-shift-2 = 'workspace 2' # Media
|
||||||
|
ctrl-shift-1 = 'move-node-to-workspace 1' # Move node to Main
|
||||||
|
ctrl-shift-2 = 'move-node-to-workspace 2' # Move node to Media
|
||||||
|
|
||||||
|
alt-shift-tab = 'workspace-back-and-forth' # Switch between workspaces
|
||||||
|
ctrl-shift-tab = 'move-workspace-to-monitor --wrap-around prev'
|
||||||
|
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/commands#mode
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/guide#binding-modes
|
||||||
|
alt-a = 'mode apps'
|
||||||
|
alt-s = 'mode service'
|
||||||
|
alt-m = 'mode move'
|
||||||
|
|
||||||
|
# ╭──────────────────────────────────────────────────────────╮
|
||||||
|
# │ alt-m │
|
||||||
|
# ╰──────────────────────────────────────────────────────────╯
|
||||||
|
[mode.move.binding]
|
||||||
|
esc = ['reload-config', 'mode main']
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/commands#move-node-to-workspace
|
||||||
|
1 = ['move-node-to-workspace 1 --focus-follows-window']
|
||||||
|
2 = ['move-node-to-workspace 2 --focus-follows-window']
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/commands#move
|
||||||
|
h = 'move left'
|
||||||
|
j = 'move down'
|
||||||
|
k = 'move up'
|
||||||
|
l = 'move right'
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/commands#join-with
|
||||||
|
shift-h = 'join-with left'
|
||||||
|
shift-j = 'join-with down'
|
||||||
|
shift-k = 'join-with up'
|
||||||
|
shift-l = 'join-with right'
|
||||||
|
# https://nikitabobko.github.io/AeroSpace/commands#resize
|
||||||
|
ctrl-h = 'resize smart -70'
|
||||||
|
ctrl-l = 'resize smart +70'
|
||||||
|
shift-left = 'resize smart +70'
|
||||||
|
shift-right = 'resize smart -70'
|
||||||
|
# https://nikitabobko.github.io/AeroSpace/commands#flatten-workspace-tree
|
||||||
|
r = ['flatten-workspace-tree', 'mode main'] # reset layout
|
||||||
|
|
||||||
|
# ╭──────────────────────────────────────────────────────────╮
|
||||||
|
# │ alt-a │
|
||||||
|
# ╰──────────────────────────────────────────────────────────╯
|
||||||
|
[mode.apps.binding]
|
||||||
|
esc = ['reload-config', 'mode main']
|
||||||
|
b = ['exec-and-forget open -a /Applications/Brave Browser.app', 'mode main'] # Browser
|
||||||
|
c = ['exec-and-forget open -a /Applications/Ferdium.app', 'mode main'] # Chat
|
||||||
|
g = ['exec-and-forget open -a /Applications/Ghostty.app', 'mode main'] # Ghostty
|
||||||
|
o = ['exec-and-forget open -a /Applications/Obsidian.app', 'mode main'] # Obsidian
|
||||||
|
s = ['exec-and-forget open -a /Applications/Slack.app', 'mode main'] # Slack
|
||||||
|
t = ['exec-and-forget open -a /Applications/TIDAL.app', 'mode main'] # Tidal
|
||||||
|
w = ['exec-and-forget open -a /Applications/WezTerm.app', 'mode main'] # WezTerm
|
||||||
|
|
||||||
|
# ╭──────────────────────────────────────────────────────────╮
|
||||||
|
# │ alt-s │
|
||||||
|
# ╰──────────────────────────────────────────────────────────╯
|
||||||
|
[mode.service.binding]
|
||||||
|
esc = ['reload-config', 'mode main'] # reload config
|
||||||
|
r = ['flatten-workspace-tree', 'mode main'] # reset layout
|
||||||
|
# See: https://nikitabobko.github.io/AeroSpace/commands#layout
|
||||||
|
f = ['layout floating tiling', 'mode main'] # Toggle between floating and tiling layout
|
||||||
|
backspace = ['close-all-windows-but-current', 'mode main']
|
||||||
52
config/alacritty/alacritty.toml
Normal file
52
config/alacritty/alacritty.toml
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
import = [
|
||||||
|
# Default to night if the copied one doesn't exist.
|
||||||
|
"~/.dotfiles/config/alacritty/theme-night.toml",
|
||||||
|
"~/.config/alacritty/theme-active.toml"
|
||||||
|
]
|
||||||
|
|
||||||
|
[env]
|
||||||
|
TERM = "xterm-256color"
|
||||||
|
|
||||||
|
[colors]
|
||||||
|
draw_bold_text_with_bright_colors = true
|
||||||
|
|
||||||
|
[font]
|
||||||
|
size = 14.0
|
||||||
|
|
||||||
|
[font.glyph_offset]
|
||||||
|
x = 0
|
||||||
|
y = 0
|
||||||
|
|
||||||
|
[font.normal]
|
||||||
|
family = "JetBrainsMonoNL Nerd Font Mono"
|
||||||
|
style = "ExtraLight"
|
||||||
|
|
||||||
|
[font.italic]
|
||||||
|
family = "JetBrainsMonoNL Nerd Font Mono"
|
||||||
|
style = "Italic"
|
||||||
|
|
||||||
|
[font.bold]
|
||||||
|
family = "JetBrainsMonoNL Nerd Font Mono"
|
||||||
|
style = "Bold"
|
||||||
|
|
||||||
|
[font.offset]
|
||||||
|
x = 0
|
||||||
|
y = 0
|
||||||
|
|
||||||
|
[selection]
|
||||||
|
semantic_escape_chars = ",│`|:\"' ()[]{}<>"
|
||||||
|
save_to_clipboard = true
|
||||||
|
|
||||||
|
[window]
|
||||||
|
decorations = "Full"
|
||||||
|
dynamic_title = true
|
||||||
|
opacity = 0.98
|
||||||
|
blur = true
|
||||||
|
|
||||||
|
[window.dimensions]
|
||||||
|
columns = 200
|
||||||
|
lines = 75
|
||||||
|
|
||||||
|
[window.padding]
|
||||||
|
x = 5
|
||||||
|
y = 5
|
||||||
40
config/alacritty/theme-day.toml
Normal file
40
config/alacritty/theme-day.toml
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
# TokyoNight Alacritty Colors: Day
|
||||||
|
# Default colors
|
||||||
|
[colors.primary]
|
||||||
|
background = '#e1e2e7'
|
||||||
|
foreground = '#3760bf'
|
||||||
|
|
||||||
|
#[colors.cursor]
|
||||||
|
#cursor = '#3760bf'
|
||||||
|
#text = '#e1e2e7'
|
||||||
|
|
||||||
|
# Normal colors
|
||||||
|
[colors.normal]
|
||||||
|
black = '#e9e9ed'
|
||||||
|
red = '#f52a65'
|
||||||
|
green = '#587539'
|
||||||
|
yellow = '#8c6c3e'
|
||||||
|
blue = '#2e7de9'
|
||||||
|
magenta = '#9854f1'
|
||||||
|
cyan = '#007197'
|
||||||
|
white = '#6172b0'
|
||||||
|
|
||||||
|
# Bright colors
|
||||||
|
[colors.bright]
|
||||||
|
black = '#a1a6c5'
|
||||||
|
red = '#f52a65'
|
||||||
|
green = '#587539'
|
||||||
|
yellow = '#8c6c3e'
|
||||||
|
blue = '#2e7de9'
|
||||||
|
magenta = '#9854f1'
|
||||||
|
cyan = '#007197'
|
||||||
|
white = '#3760bf'
|
||||||
|
|
||||||
|
# Indexed Colors
|
||||||
|
[[colors.indexed_colors]]
|
||||||
|
index = 16
|
||||||
|
color = '#b15c00'
|
||||||
|
|
||||||
|
[[colors.indexed_colors]]
|
||||||
|
index = 17
|
||||||
|
color = '#c64343'
|
||||||
40
config/alacritty/theme-night.toml
Normal file
40
config/alacritty/theme-night.toml
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
# TokyoNight Alacritty Colors: Storm
|
||||||
|
# Default colors
|
||||||
|
[colors.primary]
|
||||||
|
background = '#24283b'
|
||||||
|
foreground = '#c0caf5'
|
||||||
|
|
||||||
|
#[colors.cursor]
|
||||||
|
#cursor = '#c0caf5'
|
||||||
|
#text = '#24283b'
|
||||||
|
|
||||||
|
# Normal colors
|
||||||
|
[colors.normal]
|
||||||
|
black = '#1d202f'
|
||||||
|
red = '#f7768e'
|
||||||
|
green = '#9ece6a'
|
||||||
|
yellow = '#e0af68'
|
||||||
|
blue = '#7aa2f7'
|
||||||
|
magenta = '#bb9af7'
|
||||||
|
cyan = '#7dcfff'
|
||||||
|
white = '#a9b1d6'
|
||||||
|
|
||||||
|
# Bright colors
|
||||||
|
[colors.bright]
|
||||||
|
black = '#414868'
|
||||||
|
red = '#f7768e'
|
||||||
|
green = '#9ece6a'
|
||||||
|
yellow = '#e0af68'
|
||||||
|
blue = '#7aa2f7'
|
||||||
|
magenta = '#bb9af7'
|
||||||
|
cyan = '#7dcfff'
|
||||||
|
white = '#c0caf5'
|
||||||
|
|
||||||
|
# Indexed Colors
|
||||||
|
[[colors.indexed_colors]]
|
||||||
|
index = 16
|
||||||
|
color = '#ff9e64'
|
||||||
|
|
||||||
|
[[colors.indexed_colors]]
|
||||||
|
index = 17
|
||||||
|
color = '#db4b4b'
|
||||||
200
config/alias
200
config/alias
@@ -1,49 +1,119 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
# shellcheck source="../scripts/shared.sh"
|
|
||||||
# shellcheck disable=1091,2139
|
|
||||||
source "$DOTFILES/scripts/shared.sh"
|
|
||||||
|
|
||||||
# Get installed php versions from brew and setup aliases
|
# Color the grep output
|
||||||
function x-set-php-aliases
|
alias grep="grep --color"
|
||||||
{
|
|
||||||
have brew && {
|
|
||||||
local php_versions=()
|
|
||||||
while IFS="" read -r line; do php_versions+=("$line"); done < <(brew list | grep '^php')
|
|
||||||
|
|
||||||
php_error_reporting='-d error_reporting=22527'
|
x-have eza && {
|
||||||
|
alias ls="eza -h -s=type --git --icons --group-directories-first"
|
||||||
for version in "${php_versions[@]}"; do
|
|
||||||
# drop the dot from version (8.0 -> 80)
|
|
||||||
local php_abbr="${version//\./}"
|
|
||||||
# replace "php@" with "p" so "php@80" becomes "p80"
|
|
||||||
local php_alias="${php_abbr//php@/p}"
|
|
||||||
|
|
||||||
# Fetch the exec path once
|
|
||||||
php_exec="$(brew --prefix "$version")/bin/php"
|
|
||||||
|
|
||||||
# Raw PHP without error_reporting flag.
|
|
||||||
# shellcheck disable=SC2139
|
|
||||||
alias "${php_alias}"r="$php_exec"
|
|
||||||
# PHP with error_reporting flag.
|
|
||||||
# shellcheck disable=SC2139,SC2140
|
|
||||||
alias "$php_alias"="$php_exec $php_error_reporting"
|
|
||||||
# Local PHP Server.
|
|
||||||
# shellcheck disable=SC2139,SC2140
|
|
||||||
alias "${php_alias}s"="$php_exec -S localhost:9000"
|
|
||||||
# Use composer with specific PHP and error_reporting flag on.
|
|
||||||
# shellcheck disable=SC2139,SC2140
|
|
||||||
alias "${php_alias}c"="$php_exec $php_error_reporting $(which composer)"
|
|
||||||
done
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Easier navigation: .., ..., ....
|
||||||
|
alias ..="cd .."
|
||||||
|
alias ...="cd ../.."
|
||||||
|
alias ....="cd ../../.."
|
||||||
|
|
||||||
|
# Get git repository root path
|
||||||
|
get_git_root()
|
||||||
|
{
|
||||||
|
# check that we are in a git repository
|
||||||
|
if git rev-parse --is-inside-work-tree &> /dev/null; then
|
||||||
|
git rev-parse --show-toplevel
|
||||||
|
else
|
||||||
|
>&2 msgr err "Not in a git repository"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# cd to git root directory
|
||||||
|
alias cdgr='cd "$(get_git_root)"'
|
||||||
|
|
||||||
|
# interesting folders, and shortcuts
|
||||||
|
alias .='cd $HOME'
|
||||||
|
alias .b='cd $XDG_BIN_HOME'
|
||||||
|
alias .c='cd $HOME/Code'
|
||||||
|
alias .d='cd $DOTFILES'
|
||||||
|
alias .l='cd $HOME/.local'
|
||||||
|
alias .o='cd $HOME/Code/ivuorinen/obsidian/'
|
||||||
|
|
||||||
|
# Shortcuts for listing
|
||||||
|
alias ll="ls -la"
|
||||||
|
alias l="ls -a"
|
||||||
|
|
||||||
|
# Prevent common typos
|
||||||
|
alias cd..="cd .."
|
||||||
|
alias sl="ls"
|
||||||
|
|
||||||
|
# IP addresses
|
||||||
|
alias x-ip="dig +short myip.opendns.com @resolver1.opendns.com"
|
||||||
|
alias localip="ipconfig getifaddr en1"
|
||||||
|
alias ips="ifconfig -a | grep -o 'inet6\? \(\([0-9]\+\.[0-9]\+\.[0-9]\+\.[0-9]\+\)\|[a-fA-F0-9:]\+\)' | sed -e 's/inet6* //' | sort"
|
||||||
|
|
||||||
|
# Show/hide hidden files in Finder
|
||||||
|
alias show="defaults write com.apple.finder AppleShowAllFiles -bool true; killall Finder"
|
||||||
|
alias hide="defaults write com.apple.finder AppleShowAllFiles -bool false; killall Finder"
|
||||||
|
|
||||||
|
# Pipe public key to clipboard.
|
||||||
|
alias pubkey="more ~/.ssh/id_rsa.pub | pbcopy | echo '=> Public key copied to pasteboard.'"
|
||||||
|
|
||||||
|
# Flush Directory Service cache
|
||||||
|
alias flush="dscacheutil -flushcache"
|
||||||
|
|
||||||
|
# Update locatedb
|
||||||
|
alias updatedb="sudo /usr/libexec/locate.updatedb"
|
||||||
|
|
||||||
|
# Date helpers
|
||||||
|
alias isodate="date +'%Y-%m-%d'"
|
||||||
|
alias x-datetime="date +'%Y-%m-%d %H:%M:%S'"
|
||||||
|
alias x-timestamp="date +'%s'"
|
||||||
|
|
||||||
|
# nvim aliases
|
||||||
|
alias vi='nvim'
|
||||||
|
alias vim='nvim'
|
||||||
|
|
||||||
|
# xdg-ninja aliases for better experience
|
||||||
|
alias xdg='xdg-ninja --skip-ok --skip-unsupported'
|
||||||
|
|
||||||
|
# watch with: differences, precise, beep and color
|
||||||
|
alias watchx='watch -dpbc'
|
||||||
|
# delete .DS_Store files
|
||||||
|
alias zapds='find . -name ".DS_Store" -print -delete'
|
||||||
|
# Recursively delete `.pyc` files
|
||||||
|
alias zappyc="find . -type f -name '*.pyc' -ls -delete"
|
||||||
|
# Run all zaps
|
||||||
|
alias zapall="zapds && zappyc"
|
||||||
|
# directory usage, return only the total
|
||||||
|
alias dn='du -chd1'
|
||||||
|
# Mirror site with wget
|
||||||
|
alias mirror_site='wget -m -k -K -E -e robots=off'
|
||||||
|
# Mirror stdout to stderr, useful for seeing data going through a pipe
|
||||||
|
alias peek='tee >(cat 1>&2)'
|
||||||
|
|
||||||
|
# Runs Gitlab code quality scanner
|
||||||
|
alias code_scanner='docker run
|
||||||
|
--env SOURCE_CODE="$PWD"
|
||||||
|
--volume "${PWD}":/code
|
||||||
|
--volume /var/run/docker.sock:/var/run/docker.sock
|
||||||
|
registry.gitlab.com/gitlab-org/ci-cd/codequality:"${CODEQUALITY_VERSION:-latest}"
|
||||||
|
/code'
|
||||||
|
|
||||||
|
# Runs trivy container image scanner
|
||||||
|
alias trivy_scan='docker run -v /var/run/docker.sock:/var/run/docker.sock -v $HOME/Library/Caches:/root/.cache/ aquasec/trivy'
|
||||||
|
# Opens dotfiles with $EDITOR
|
||||||
|
alias zedit='$EDITOR ~/.dotfiles'
|
||||||
|
# Open irssi with my configurations
|
||||||
|
alias irssi='irssi --config=$XDG_CONFIG_HOME/irssi/config --home=$XDG_CONFIG_HOME/irssi'
|
||||||
|
# Configures wget to use correct wget-hsts file
|
||||||
|
alias wget='wget --hsts-file=$XDG_DATA_HOME/wget-hsts'
|
||||||
|
# Configures svn to use correct config directory
|
||||||
|
alias svn='svn --config-dir $XDG_CONFIG_HOME/subversion'
|
||||||
|
|
||||||
|
# Laravel artisan shortcut
|
||||||
|
alias art='[ -f artisan ] && php artisan || php vendor/bin/artisan'
|
||||||
|
|
||||||
|
# Laravel Sail shortcut
|
||||||
|
alias sail='[ -f sail ] && bash sail || bash vendor/bin/sail'
|
||||||
|
|
||||||
if [[ $(uname) == 'Darwin' ]]; then
|
if [[ $(uname) == 'Darwin' ]]; then
|
||||||
|
|
||||||
x-set-php-aliases
|
|
||||||
|
|
||||||
# Laravel Sail shortcut
|
|
||||||
alias sail='[ -f sail ] && bash sail || bash vendor/bin/sail'
|
|
||||||
|
|
||||||
# Flush Directory Service cache
|
# Flush Directory Service cache
|
||||||
alias flushdns="sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder"
|
alias flushdns="sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder"
|
||||||
|
|
||||||
@@ -51,44 +121,20 @@ if [[ $(uname) == 'Darwin' ]]; then
|
|||||||
alias afk="osascript -e 'tell application \"System Events\" to keystroke \"q\" using {command down,control down}'"
|
alias afk="osascript -e 'tell application \"System Events\" to keystroke \"q\" using {command down,control down}'"
|
||||||
|
|
||||||
# Empty the Trash on all mounted volumes and the main HDD
|
# Empty the Trash on all mounted volumes and the main HDD
|
||||||
# Also, clear Apple’s System Logs to improve shell startup speed
|
# Also, clear Apple's System Logs to improve shell startup speed
|
||||||
alias emptytrash="sudo rm -rfv /Volumes/*/.Trashes; sudo rm -rfv ~/.Trash; sudo rm -rfv /private/var/log/asl/*.asl"
|
alias emptytrash="sudo rm -rfv /Volumes/*/.Trashes; sudo rm -rfv ~/.Trash; sudo rm -rfv /private/var/log/asl/*.asl"
|
||||||
|
|
||||||
|
# Using herd for php now, so this is not needed anymore
|
||||||
|
# x-set-php-aliases
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# tmux: automatically attach or create session with name 'main'
|
X_ALIAS_FILES=(
|
||||||
alias tmux='tmux new-session -A -s main'
|
"$HOME/.config/alias-secret"
|
||||||
# tmux: attach or create new session
|
"$HOME/.config/alias-$(hostname)"
|
||||||
alias ta='tmux attach || tmux'
|
"$HOME/.config/alias-$(hostname)-secret"
|
||||||
|
)
|
||||||
# watch with: differences, precise, beep and color
|
for aliasFile in "${X_ALIAS_FILES[@]}"; do
|
||||||
alias watchx='watch -dpbc'
|
# shellcheck source=$HOME/.config/alias-secret
|
||||||
# delete .DS_Store files
|
[ -f "$aliasFile" ] && source "$aliasFile" && msgr ok "Sourced $aliasFile"
|
||||||
alias zapds='find . -name ".DS_Store" -print -delete'
|
done
|
||||||
# tail with follow flag on
|
unset X_ALIAS_FILES
|
||||||
alias t='tail -f'
|
|
||||||
# directory usage, return only the total
|
|
||||||
alias dn='du -chd1'
|
|
||||||
# Mirror site with wget
|
|
||||||
alias mirror_site='wget -m -k -K -E -e robots=off'
|
|
||||||
# Mirror stdout to stderr, useful for seeing data going through a pipe
|
|
||||||
alias peek='tee >(cat 1>&2)'
|
|
||||||
|
|
||||||
alias code_scanner='docker run
|
|
||||||
--env SOURCE_CODE="$PWD"
|
|
||||||
--volume "${PWD}":/code
|
|
||||||
--volume /var/run/docker.sock:/var/run/docker.sock
|
|
||||||
registry.gitlab.com/gitlab-org/ci-cd/codequality:"${CODEQUALITY_VERSION:-latest}"
|
|
||||||
/code'
|
|
||||||
|
|
||||||
alias zedit='$EDITOR ~/.dotfiles'
|
|
||||||
|
|
||||||
have irssi \
|
|
||||||
&& alias irssi="irssi --config='$IRSSI_CONFIG_FILE' --home='$IRSSI_CONFIG_HOME'"
|
|
||||||
|
|
||||||
if [[ -f "$HOME/.aliases.local" ]]; then
|
|
||||||
# shellcheck disable=SC1091
|
|
||||||
source "$HOME/.aliases.local"
|
|
||||||
fi
|
|
||||||
|
|
||||||
alias wget=wget --hsts-file="$XDG_DATA_HOME/wget-hsts"
|
|
||||||
alias svn="svn --config-dir $XDG_CONFIG_HOME/subversion"
|
|
||||||
|
|||||||
@@ -1,4 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
# Setting aliases for tunkki
|
|
||||||
|
|
||||||
alias nvim="/snap/nvim/current/usr/bin/nvim"
|
|
||||||
364
config/amethyst/amethyst.yml
Normal file
364
config/amethyst/amethyst.yml
Normal file
@@ -0,0 +1,364 @@
|
|||||||
|
---
|
||||||
|
# Default settings for amethyst
|
||||||
|
# Repo: `https://github.com/ianyh/Amethyst`
|
||||||
|
#
|
||||||
|
# Note due to issue 1419 (https://github.com/ianyh/Amethyst/issues/1419) some
|
||||||
|
# config values may conflict and not work if they are the same as the default
|
||||||
|
# values for amathyst. You can see these values on GitHub at
|
||||||
|
# https://github.com/ianyh/Amethyst/blob/development/Amethyst/default.amethyst
|
||||||
|
# If you're experiencing conflicts and the settings are the same as the default,
|
||||||
|
# comment out the commands in this file.
|
||||||
|
#
|
||||||
|
# Move this file to: `~/.amethyst.yml`
|
||||||
|
# In order to register changes restart Amethyst.
|
||||||
|
# If you experience issues pulling in the changes you can also
|
||||||
|
# quit Amethyst and run: `defaults delete com.amethyst.Amethyst.plist`
|
||||||
|
# This removes the current preferences and causes Amethyst to restart
|
||||||
|
# with default preferences and pull configs from this file.
|
||||||
|
|
||||||
|
# layouts - Ordered list of layouts to use by layout key
|
||||||
|
# (default tall, wide, fullscreen, and column).
|
||||||
|
layouts:
|
||||||
|
- bsp
|
||||||
|
- tall
|
||||||
|
# - fullscreen
|
||||||
|
# - tall-right
|
||||||
|
# - wide
|
||||||
|
# - two-pane
|
||||||
|
# - middle-wide
|
||||||
|
- 3column-left
|
||||||
|
# - 3column-middle
|
||||||
|
# - 3column-right
|
||||||
|
# - 4column-left
|
||||||
|
# - 4column-right
|
||||||
|
# - column
|
||||||
|
# - row
|
||||||
|
# - floating
|
||||||
|
- widescreen-tall
|
||||||
|
# - widescreen-tall-right
|
||||||
|
# - bsp
|
||||||
|
|
||||||
|
# First mod (default option + shift).
|
||||||
|
mod1:
|
||||||
|
- option
|
||||||
|
- shift
|
||||||
|
# - control
|
||||||
|
# - command
|
||||||
|
|
||||||
|
# Second mod (default option + shift + control).
|
||||||
|
mod2:
|
||||||
|
- option
|
||||||
|
- shift
|
||||||
|
- control
|
||||||
|
# - command
|
||||||
|
|
||||||
|
# Commands:
|
||||||
|
# special key values
|
||||||
|
# space
|
||||||
|
# enter
|
||||||
|
# up
|
||||||
|
# right
|
||||||
|
# down
|
||||||
|
# left
|
||||||
|
|
||||||
|
# special characters require quotes
|
||||||
|
# '.'
|
||||||
|
# ','
|
||||||
|
|
||||||
|
# Move to the next layout in the list.
|
||||||
|
cycle-layout:
|
||||||
|
mod: mod1
|
||||||
|
key: space
|
||||||
|
|
||||||
|
# Move to the previous layout in the list.
|
||||||
|
cycle-layout-backward:
|
||||||
|
mod: mod2
|
||||||
|
key: space
|
||||||
|
|
||||||
|
# Shrink the main pane by a percentage of the screen
|
||||||
|
# dimension as defined by window-resize-step.
|
||||||
|
# Note that not all layouts respond to this command.
|
||||||
|
shrink-main:
|
||||||
|
mod: mod1
|
||||||
|
key: h
|
||||||
|
|
||||||
|
# Expand the main pane by a percentage of the screen dimension
|
||||||
|
# as defined by window-resize-step. Note that not all layouts
|
||||||
|
# respond to this command.
|
||||||
|
expand-main:
|
||||||
|
mod: mod1
|
||||||
|
key: l
|
||||||
|
|
||||||
|
# Increase the number of windows in the main pane.
|
||||||
|
# Note that not all layouts respond to this command.
|
||||||
|
increase-main:
|
||||||
|
mod: mod1
|
||||||
|
key: ','
|
||||||
|
|
||||||
|
# Decrease the number of windows in the main pane.
|
||||||
|
# Note that not all layouts respond to this command.
|
||||||
|
decrease-main:
|
||||||
|
mod: mod1
|
||||||
|
key: '.'
|
||||||
|
|
||||||
|
# General purpose command for custom layouts.
|
||||||
|
# Functionality is layout-dependent.
|
||||||
|
# command1:
|
||||||
|
# mod: <NONE>
|
||||||
|
# key: <NONE>
|
||||||
|
# General purpose command for custom layouts.
|
||||||
|
# Functionality is layout-dependent.
|
||||||
|
# command2:
|
||||||
|
# mod: <NONE>
|
||||||
|
# key: <NONE>
|
||||||
|
# General purpose command for custom layouts.
|
||||||
|
# Functionality is layout-dependent.
|
||||||
|
# command3:
|
||||||
|
# mod: <NONE>
|
||||||
|
# key: <NONE>
|
||||||
|
# General purpose command for custom layouts.
|
||||||
|
# Functionality is layout-dependent.
|
||||||
|
# command4:
|
||||||
|
# mod: <NONE>
|
||||||
|
# key: <NONE>
|
||||||
|
|
||||||
|
# Focus the next window in the list going counter-clockwise.
|
||||||
|
focus-ccw:
|
||||||
|
mod: mod1
|
||||||
|
key: j
|
||||||
|
|
||||||
|
# Focus the next window in the list going clockwise.
|
||||||
|
focus-cw:
|
||||||
|
mod: mod1
|
||||||
|
key: k
|
||||||
|
|
||||||
|
# Focus the main window in the list.
|
||||||
|
focus-main:
|
||||||
|
mod: mod1
|
||||||
|
key: m
|
||||||
|
|
||||||
|
# Focus the next screen in the list going counter-clockwise.
|
||||||
|
focus-screen-ccw:
|
||||||
|
mod: mod1
|
||||||
|
key: p
|
||||||
|
|
||||||
|
# Focus the next screen in the list going clockwise.
|
||||||
|
focus-screen-cw:
|
||||||
|
mod: mod1
|
||||||
|
key: n
|
||||||
|
|
||||||
|
# Move the currently focused window onto the next
|
||||||
|
# screen in the list going counter-clockwise.
|
||||||
|
swap-screen-ccw:
|
||||||
|
mod: mod2
|
||||||
|
key: h
|
||||||
|
|
||||||
|
# Move the currently focused window onto the next
|
||||||
|
# screen in the list going clockwise.
|
||||||
|
swap-screen-cw:
|
||||||
|
mod: mod2
|
||||||
|
key: l
|
||||||
|
|
||||||
|
# Swap the position of the currently focused window with
|
||||||
|
# the next window in the list going counter-clockwise.
|
||||||
|
swap-ccw:
|
||||||
|
mod: mod2
|
||||||
|
key: j
|
||||||
|
|
||||||
|
# Swap the position of the currently focused window with
|
||||||
|
# the next window in the list going clockwise.
|
||||||
|
swap-cw:
|
||||||
|
mod: mod2
|
||||||
|
key: k
|
||||||
|
|
||||||
|
# Swap the position of the currently focused window
|
||||||
|
# with the main window in the list.
|
||||||
|
swap-main:
|
||||||
|
mod: mod1
|
||||||
|
key: enter
|
||||||
|
|
||||||
|
# Move focus to the n-th screen in the list; e.g.,
|
||||||
|
# focus-screen-3 will move mouse focus to the 3rd screen.
|
||||||
|
# Note that the main window in the given screen will be focused.
|
||||||
|
#focus-screen-n:
|
||||||
|
# focus-screen-<screen-number>:
|
||||||
|
# mod: mod1
|
||||||
|
# key: y
|
||||||
|
# Move the currently focused window to the n-th screen;
|
||||||
|
# e.g., throw-screen-3 will move the window to the 3rd screen.
|
||||||
|
# throw-screen-n:
|
||||||
|
# throw-screen-<screen-number>:
|
||||||
|
# mod: mod1
|
||||||
|
# key: u
|
||||||
|
# Move the currently focused window to the n-th space;
|
||||||
|
# e.g., throw-space-3 will move the window to the 3rd space.
|
||||||
|
# throw-space-<screen-number>:
|
||||||
|
# mod: mod1
|
||||||
|
# key: i
|
||||||
|
|
||||||
|
# Select tall layout
|
||||||
|
#select-tall-layout:
|
||||||
|
# mod: mod1
|
||||||
|
# key: a
|
||||||
|
|
||||||
|
# Select wide layout
|
||||||
|
#select-wide-layout:
|
||||||
|
# mod: mod1
|
||||||
|
# key: s
|
||||||
|
|
||||||
|
# Select fullscreen layout
|
||||||
|
select-fullscreen-layout:
|
||||||
|
mod: mod1
|
||||||
|
key: d
|
||||||
|
|
||||||
|
# Select column layout
|
||||||
|
select-column-layout:
|
||||||
|
mod: mod1
|
||||||
|
key: f
|
||||||
|
|
||||||
|
# Move the currently focused window to the space to the left.
|
||||||
|
throw-space-left:
|
||||||
|
mod: mod2
|
||||||
|
key: left
|
||||||
|
|
||||||
|
# Move currently the focused window to the space to the right.
|
||||||
|
throw-space-right:
|
||||||
|
mod: mod2
|
||||||
|
key: right
|
||||||
|
|
||||||
|
# Toggle the floating state of the currently focused window;
|
||||||
|
# i.e., if it was floating make it tiled and if it was
|
||||||
|
# tiled make it floating.
|
||||||
|
toggle-float:
|
||||||
|
mod: mod1
|
||||||
|
key: t
|
||||||
|
|
||||||
|
# Display the layout HUD with the current layout on each screen.
|
||||||
|
display-current-layout:
|
||||||
|
mod: mod1
|
||||||
|
key: i
|
||||||
|
|
||||||
|
# Turn on or off tiling entirely.
|
||||||
|
toggle-tiling:
|
||||||
|
mod: mod1
|
||||||
|
key: t
|
||||||
|
|
||||||
|
# Rerun the current layout's algorithm.
|
||||||
|
reevaluate-windows:
|
||||||
|
mod: mod1
|
||||||
|
key: z
|
||||||
|
|
||||||
|
# Turn on or off focus-follows-mouse.
|
||||||
|
toggle-focus-follows-mouse:
|
||||||
|
mod: mod2
|
||||||
|
key: x
|
||||||
|
|
||||||
|
# Automatically quit and reopen Amethyst.
|
||||||
|
relaunch-amethyst:
|
||||||
|
mod: mod2
|
||||||
|
key: z
|
||||||
|
|
||||||
|
# disable screen padding on builtin display
|
||||||
|
disable-padding-on-builtin-display: false
|
||||||
|
|
||||||
|
# Boolean flag for whether to add margins between
|
||||||
|
# windows (default false).
|
||||||
|
window-margins: false
|
||||||
|
|
||||||
|
# Boolean flag for whether to set window margins if there is
|
||||||
|
# only one window on the screen, assuming window margins
|
||||||
|
# are enabled (default false).
|
||||||
|
smart-window-margins: true
|
||||||
|
|
||||||
|
# # Add 10px margin between windows
|
||||||
|
# window-margins: true
|
||||||
|
# window-margin-size: 5
|
||||||
|
# The size of the margins between windows (in px, default 0).
|
||||||
|
window-margin-size: 0
|
||||||
|
|
||||||
|
# The max number of windows that may be visible on a screen
|
||||||
|
# at one time before additional windows are minimized.
|
||||||
|
# A value of 0 disables the feature.
|
||||||
|
window-max-count: 0
|
||||||
|
|
||||||
|
# The smallest height that a window can be sized to
|
||||||
|
# regardless of its layout frame (in px, default 0).
|
||||||
|
window-minimum-height: 0
|
||||||
|
|
||||||
|
# The smallest width that a window can be sized to
|
||||||
|
# regardless of its layout frame (in px, default 0)
|
||||||
|
window-minimum-width: 0
|
||||||
|
|
||||||
|
# List of bundle identifiers for applications to either be automatically
|
||||||
|
# floating or automatically tiled based on floating-is-blacklist (default []).
|
||||||
|
floating: []
|
||||||
|
|
||||||
|
# Boolean flag determining behavior of the floating list.
|
||||||
|
# true if the applications should be floating and all others tiled.
|
||||||
|
# false if the applications should be tiled and all others floating (default true).
|
||||||
|
floating-is-blacklist: false
|
||||||
|
|
||||||
|
# true if screen frames should exclude the status bar.
|
||||||
|
# false if the screen frames should include the status bar (default false).
|
||||||
|
ignore-menu-bar: false
|
||||||
|
|
||||||
|
# true if windows smaller than a 500px square should
|
||||||
|
# be floating by default (default true)
|
||||||
|
float-small-windows: true
|
||||||
|
|
||||||
|
# true if the mouse should move position to the center of a window
|
||||||
|
# when it becomes focused (default false).
|
||||||
|
# Note that this is largely incompatible with focus-follows-mouse.
|
||||||
|
mouse-follows-focus: false
|
||||||
|
|
||||||
|
# true if the windows underneath the mouse should become focused as
|
||||||
|
# the mouse moves (default false). Note that this is largely
|
||||||
|
# incompatible with mouse-follows-focus
|
||||||
|
focus-follows-mouse: false
|
||||||
|
|
||||||
|
# true if dragging and dropping windows on to each other
|
||||||
|
# should swap their positions (default false).
|
||||||
|
mouse-swaps-windows: true
|
||||||
|
|
||||||
|
# true if changing the frame of a window with the mouse should update the
|
||||||
|
# layout to accommodate the change (default false).
|
||||||
|
# Note that not all layouts will be able to respond to the change.
|
||||||
|
mouse-resizes-windows: true
|
||||||
|
|
||||||
|
# true to display the name of the layout when a new layout is selected (default true).
|
||||||
|
enables-layout-hud: true
|
||||||
|
|
||||||
|
# true to display the name of the layout when moving to a new space (default true).
|
||||||
|
enables-layout-hud-on-space-change: true
|
||||||
|
|
||||||
|
# true to get updates to beta versions of the software (default false).
|
||||||
|
use-canary-build: false
|
||||||
|
|
||||||
|
# true to insert new windows into the first position and
|
||||||
|
# false to insert new windows into the last position (default false).
|
||||||
|
new-windows-to-main: false
|
||||||
|
|
||||||
|
# true to automatically move to a space when throwing a window to it (default true).
|
||||||
|
follow-space-thrown-windows: true
|
||||||
|
|
||||||
|
# The integer percentage of the screen dimension to increment
|
||||||
|
# and decrement main pane ratios by (default 5).
|
||||||
|
window-resize-step: 5
|
||||||
|
|
||||||
|
# Padding to apply between windows and the left edge of the screen (in px, default 0).
|
||||||
|
screen-padding-left: 0
|
||||||
|
|
||||||
|
# Padding to apply between windows and the right edge of the screen (in px, default 0).
|
||||||
|
screen-padding-right: 0
|
||||||
|
|
||||||
|
# Padding to apply between windows and the top edge of the screen (in px, default 0).
|
||||||
|
screen-padding-top: 0
|
||||||
|
|
||||||
|
# Padding to apply between windows and the bottom edge of the screen (in px, default 0).
|
||||||
|
screen-padding-bottom: 0
|
||||||
|
|
||||||
|
# true to maintain layout state across application executions (default true).
|
||||||
|
restore-layouts-on-launch: true
|
||||||
|
|
||||||
|
# true to display some optional debug information in the layout HUD (default false).
|
||||||
|
debug-layout-info: true
|
||||||
35
config/amethyst/layouts/almost-maximize.js
Normal file
35
config/amethyst/layouts/almost-maximize.js
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
/**
|
||||||
|
* Almost Maximize
|
||||||
|
* Almost maximizes the window to the screen, leaving a small margin.
|
||||||
|
*
|
||||||
|
* @author Ville Viklund <https://github.com/ville6000>
|
||||||
|
*
|
||||||
|
* @param {Object} windows - All windows in the current space.
|
||||||
|
* @param {Object} screenFrame - The frame of the current screen.
|
||||||
|
* @param {Object} state - The state of the current space.
|
||||||
|
* @param {Object} extendedFrames - The frames of the windows in the current space.
|
||||||
|
* @return {Object} - The frames for the windows in the current space.
|
||||||
|
*/
|
||||||
|
function layout() {
|
||||||
|
return {
|
||||||
|
name: 'Almost Maximize',
|
||||||
|
getFrameAssignments: (windows, screenFrame, state, extendedFrames) => {
|
||||||
|
const width = screenFrame.width * 0.95
|
||||||
|
const height = screenFrame.height * 0.95
|
||||||
|
const x = (screenFrame.width - width) / 2
|
||||||
|
const y = (screenFrame.height - height) / 2
|
||||||
|
const windowFrames = {}
|
||||||
|
|
||||||
|
windows.forEach(window => {
|
||||||
|
windowFrames[window.id] = {
|
||||||
|
Y: screenFrame.y + y,
|
||||||
|
x: screenFrame.x + x,
|
||||||
|
width,
|
||||||
|
height,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
return windowFrames
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
3
config/asdf-direnv/zshrc
Normal file
3
config/asdf-direnv/zshrc
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
### Do not edit. This was autogenerated by 'asdf direnv setup' ###
|
||||||
|
export ASDF_DIRENV_BIN="$(asdf where direnv)/bin/direnv"
|
||||||
|
eval "$($ASDF_DIRENV_BIN hook zsh)"
|
||||||
5
config/asdf/asdfrc
Normal file
5
config/asdf/asdfrc
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
# See the docs for explanations: https://asdf-vm.com/manage/configuration.html
|
||||||
|
|
||||||
|
legacy_version_file=yes
|
||||||
|
use_release_candidates=no
|
||||||
|
concurrency=auto
|
||||||
25
config/asdf/cargo-packages
Normal file
25
config/asdf/cargo-packages
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
// A cargo subcommand for checking and applying
|
||||||
|
// updates to installed executables
|
||||||
|
cargo-update
|
||||||
|
// Cargo cache management utility
|
||||||
|
cargo-cache
|
||||||
|
// An incremental parsing system for programming tools
|
||||||
|
tree-sitter-cli
|
||||||
|
// a subprocess caching utility
|
||||||
|
bkt
|
||||||
|
// a structural diff that understands syntax
|
||||||
|
difftastic
|
||||||
|
// A simple, fast and user-friendly alternative to 'find'
|
||||||
|
fd-find
|
||||||
|
// recursively searches directories for a
|
||||||
|
// regex pattern while respecting your gitignore
|
||||||
|
ripgrep
|
||||||
|
// A version manager for neovim
|
||||||
|
bob-nvim
|
||||||
|
// bottom, btm - A cross-platform graphical process/system monitor with
|
||||||
|
// a customizable interface and a multitude of features.
|
||||||
|
bottom
|
||||||
|
// A modern alternative to ls
|
||||||
|
eza
|
||||||
|
// Tmux Sessionizer: A tool for opening git repositories as tmux sessions
|
||||||
|
tmux-sessionizer
|
||||||
1
config/asdf/gem-packages
Normal file
1
config/asdf/gem-packages
Normal file
@@ -0,0 +1 @@
|
|||||||
|
bundler
|
||||||
21
config/asdf/golang-packages
Normal file
21
config/asdf/golang-packages
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
// These are golang packages I use,
|
||||||
|
// so they should be available with all versions
|
||||||
|
|
||||||
|
// Git Profile allows you to switch between user profiles in git repos
|
||||||
|
github.com/dotzero/git-profile@v1.4.0
|
||||||
|
// An extensible command line tool or library to format yaml files.
|
||||||
|
github.com/google/yamlfmt/cmd/yamlfmt@v0.13.0
|
||||||
|
// Parsing HTML at the command line
|
||||||
|
github.com/ericchiang/pup@v0.4.0
|
||||||
|
// HTML to Markdown converter
|
||||||
|
github.com/suntong/html2md@v1.5.0
|
||||||
|
// cheat allows you to create and view interactive cheatsheets on the cli.
|
||||||
|
github.com/cheat/cheat/cmd/cheat@4.4.2
|
||||||
|
// Render markdown on the CLI, with pizzazz! 💅
|
||||||
|
github.com/charmbracelet/glow@v1.5.1
|
||||||
|
// Static checker for GitHub Actions workflow files
|
||||||
|
github.com/rhysd/actionlint/cmd/actionlint@v1.7.1
|
||||||
|
// Cleans up your $HOME from those pesky dotfiles
|
||||||
|
github.com/doron-cohen/antidot@v0.6.3
|
||||||
|
// FZF is a general-purpose command-line fuzzy finder.
|
||||||
|
github.com/junegunn/fzf@latest
|
||||||
7
config/asdf/npm-packages
Normal file
7
config/asdf/npm-packages
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
blade-formatter
|
||||||
|
corepack
|
||||||
|
editorconfig-checker
|
||||||
|
github-release-notes
|
||||||
|
neovim
|
||||||
|
npm
|
||||||
|
stylelint-lsp
|
||||||
20
config/asdf/plugin-versions
Normal file
20
config/asdf/plugin-versions
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
1password-cli https://github.com/NeoHsu/asdf-1password-cli.git f5d5aab
|
||||||
|
age https://github.com/threkk/asdf-age.git 396bdf6
|
||||||
|
asdf-plugin-manager https://github.com/asdf-community/asdf-plugin-manager.git b5862c1
|
||||||
|
direnv https://github.com/asdf-community/asdf-direnv.git 6ff3dbe
|
||||||
|
dotenv-linter https://github.com/wesleimp/asdf-dotenv-linter.git 1369f53
|
||||||
|
editorconfig-checker https://github.com/gabitchov/asdf-editorconfig-checker.git 585c1d5
|
||||||
|
fd https://gitlab.com/wt0f/asdf-fd.git 17d56e0
|
||||||
|
github-cli https://github.com/bartlomiejdanek/asdf-github-cli.git e0605b7
|
||||||
|
golang https://github.com/asdf-community/asdf-golang.git e2527a3
|
||||||
|
hadolint https://github.com/devlincashman/asdf-hadolint.git c8eb88b
|
||||||
|
kubectl https://github.com/asdf-community/asdf-kubectl.git 2fb3b57
|
||||||
|
pre-commit https://github.com/jonathanmorley/asdf-pre-commit.git 26bfc42
|
||||||
|
ripgrep https://gitlab.com/wt0f/asdf-ripgrep.git e836665
|
||||||
|
rust https://github.com/code-lever/asdf-rust.git 95acf4f
|
||||||
|
shellcheck https://github.com/luizm/asdf-shellcheck.git 66200ff
|
||||||
|
shfmt https://github.com/luizm/asdf-shfmt.git a42c5ff
|
||||||
|
terragrunt https://github.com/ohmer/asdf-terragrunt.git 29f2935
|
||||||
|
tf-summarize https://github.com/adamcrews/asdf-tf-summarize.git 880ad26
|
||||||
|
yamllint https://github.com/ericcornelissen/asdf-yamllint.git e4cfb17
|
||||||
|
yq https://github.com/sudermanjr/asdf-yq.git 772992f
|
||||||
4
config/asdf/python-packages
Normal file
4
config/asdf/python-packages
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
ansible
|
||||||
|
pipenv
|
||||||
|
neovim
|
||||||
|
libtmux
|
||||||
73
config/cheat/cheatsheets/personal/printf
Normal file
73
config/cheat/cheatsheets/personal/printf
Normal file
@@ -0,0 +1,73 @@
|
|||||||
|
---
|
||||||
|
tags: [printf, bash, zsh]
|
||||||
|
---
|
||||||
|
|
||||||
|
# printf
|
||||||
|
|
||||||
|
The printf command accepts the following syntax:
|
||||||
|
|
||||||
|
`printf [-v var] [format specifiers] [arguments]`
|
||||||
|
|
||||||
|
- [-v var]
|
||||||
|
The optional -v flag assigns the output to the [var]
|
||||||
|
variable instead of printing it in standard output.
|
||||||
|
|
||||||
|
- [format specifiers]
|
||||||
|
Format specifiers are strings that determine the methods of
|
||||||
|
formatting specifiers. The following section includes a
|
||||||
|
list of accepted specifiers.
|
||||||
|
|
||||||
|
- [arguments]
|
||||||
|
Arguments can be any value or variable, and the [format specifiers]
|
||||||
|
point to the [arguments]. If there are more arguments than format
|
||||||
|
specifiers, the format string is reused until it interprets
|
||||||
|
the last argument.
|
||||||
|
|
||||||
|
If there are fewer format specifiers than arguments, number formats
|
||||||
|
are set to zero (0), while string formats are set to null (empty).
|
||||||
|
|
||||||
|
## printf Specifiers
|
||||||
|
|
||||||
|
Format Description
|
||||||
|
------ -----------
|
||||||
|
%c Treat the arguments as a single character.
|
||||||
|
%d Treat the input as a decimal (integer) number (base 10).
|
||||||
|
%e Treats the input as an exponential floating-point number.
|
||||||
|
%f Treat the input as a floating-point number.
|
||||||
|
%i Treat the input as an integer number (base 10).
|
||||||
|
%o Treats the input as an octal number (base 8).
|
||||||
|
%s Treat the input as a string of characters.
|
||||||
|
%u Treat the input as an unsigned decimal (integer) number.
|
||||||
|
%x Treats the input as a hexadecimal number (base 16).
|
||||||
|
%% Print a percent sign.
|
||||||
|
%Wd Print the W integer X digits wide.
|
||||||
|
%(format)T Outputs a date-time string resulting from using format as a
|
||||||
|
format string for strftime. The corresponding argument can
|
||||||
|
be the number of seconds since Epoch (January 1, 1970, 00:00),
|
||||||
|
-1 (the current time), or -2 (shell startup time).
|
||||||
|
Not specifying an argument uses the current time as the default value.
|
||||||
|
\% Print a percent sign.
|
||||||
|
\n Prints a newline character.
|
||||||
|
\t Print a tab character.
|
||||||
|
|
||||||
|
Some format specifiers accept format modifiers that modify their actions.
|
||||||
|
Enter the modifiers between the % character and the character that
|
||||||
|
specifies the format.
|
||||||
|
|
||||||
|
Available format modifiers are:
|
||||||
|
|
||||||
|
<N>. Enter a number that specifies a minimum field width.
|
||||||
|
If the output text is shorter, it's padded with spaces.
|
||||||
|
If the text is longer, the field expands.
|
||||||
|
. (dot). When used with a field width modifier, the field doesn't
|
||||||
|
expand for longer text. Instead, the text is truncated.
|
||||||
|
-. Left-aligns the printed text. The default alignment is right.
|
||||||
|
0. Pads the numbers with zeros instead of spaces.
|
||||||
|
<space>. Pads a positive number with a space, and a negative
|
||||||
|
number with a minus (-).
|
||||||
|
+. Prints all numbers signed (+ for positive, - for negative).
|
||||||
|
'. For decimal conversions, applies the thousands grouping
|
||||||
|
separator to the integer portion of the output according
|
||||||
|
to the current LC_NUMERIC file.
|
||||||
|
|
||||||
|
|
||||||
1
config/cheat/cheatsheets/tldr
Submodule
1
config/cheat/cheatsheets/tldr
Submodule
Submodule config/cheat/cheatsheets/tldr added at a60bdfc18c
@@ -1,12 +1,13 @@
|
|||||||
|
---
|
||||||
# The editor to use with 'cheat -e <sheet>'. Defaults to $EDITOR or $VISUAL.
|
# The editor to use with 'cheat -e <sheet>'. Defaults to $EDITOR or $VISUAL.
|
||||||
# editor: $EDITOR
|
# editor: $EDITOR
|
||||||
|
|
||||||
# Should 'cheat' always colorize output?
|
# Should 'cheat' always colorize output?
|
||||||
colorize: true
|
colorize: false
|
||||||
# Which 'chroma' colorscheme should be applied to the output?
|
# Which 'chroma' colorscheme should be applied to the output?
|
||||||
# Options are available here:
|
# Options are available here:
|
||||||
# https://github.com/alecthomas/chroma/tree/master/styles
|
# https://github.com/alecthomas/chroma/tree/master/styles
|
||||||
style: "catppuccin"
|
# style: 'tokyonight-day'
|
||||||
# Which 'chroma' "formatter" should be applied?
|
# Which 'chroma' "formatter" should be applied?
|
||||||
# One of: "terminal", "terminal256", "terminal16m"
|
# One of: "terminal", "terminal256", "terminal16m"
|
||||||
formatter: terminal256
|
formatter: terminal256
|
||||||
@@ -37,7 +38,7 @@ pager: less -FRX
|
|||||||
#
|
#
|
||||||
# This is very useful when you would like to maintain, for example, a
|
# This is very useful when you would like to maintain, for example, a
|
||||||
# "pristine" repository of community cheatsheets on one cheatpath, and an
|
# "pristine" repository of community cheatsheets on one cheatpath, and an
|
||||||
# editable personal reponsity of cheatsheets on another cheatpath.
|
# editable personal repository of cheatsheets on another cheatpath.
|
||||||
#
|
#
|
||||||
# Cheatpaths can be also configured to automatically apply tags to cheatsheets
|
# Cheatpaths can be also configured to automatically apply tags to cheatsheets
|
||||||
# on certain paths, which can be useful for querying purposes.
|
# on certain paths, which can be useful for querying purposes.
|
||||||
@@ -60,20 +61,20 @@ cheatpaths:
|
|||||||
path: ~/.config/cheat/cheatsheets/community
|
path: ~/.config/cheat/cheatsheets/community
|
||||||
tags: [community]
|
tags: [community]
|
||||||
readonly: true
|
readonly: true
|
||||||
|
- name: pure-bash-bible
|
||||||
|
path: ~/.dotfiles/config/cheat/cheatsheets/pure-bash-bible
|
||||||
|
tags: [pure-bash-bible]
|
||||||
|
readonly: true
|
||||||
|
- name: tldr
|
||||||
|
path: ~/.dotfiles/config/cheat/cheatsheets/tldr/tldr
|
||||||
|
tags: [tldr]
|
||||||
|
readonly: true
|
||||||
# If you have personalized cheatsheets, list them last. They will take
|
# If you have personalized cheatsheets, list them last. They will take
|
||||||
# precedence over the more global cheatsheets.
|
# precedence over the more global cheatsheets.
|
||||||
- name: personal
|
- name: personal
|
||||||
path: ~/.dotfiles/config/cheat/cheatsheets/personal
|
path: ~/.dotfiles/config/cheat/cheatsheets/personal
|
||||||
tags: [personal]
|
tags: [personal]
|
||||||
readonly: false
|
readonly: false
|
||||||
- name: pure-bash-bible
|
|
||||||
path: ~/.dotfiles/config/cheat/cheatsheets/pure-bash-bible
|
|
||||||
tags: [pure-bash-bible]
|
|
||||||
readonly: true
|
|
||||||
- name: tldr
|
|
||||||
path: ~/.dotfiles/config/cheat/cheatsheets/tldr
|
|
||||||
tags: [tldr]
|
|
||||||
readonly: true
|
|
||||||
|
|
||||||
# While it requires no configuration here, it's also worth noting that
|
# While it requires no configuration here, it's also worth noting that
|
||||||
# cheat will automatically append directories named '.cheat' within the
|
# cheat will automatically append directories named '.cheat' within the
|
||||||
|
|||||||
13
config/direnv/direnv.toml
Normal file
13
config/direnv/direnv.toml
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
[global]
|
||||||
|
disable_stdin = false
|
||||||
|
load_dotenv = true
|
||||||
|
hide_env_diff = false
|
||||||
|
|
||||||
|
[whitelist]
|
||||||
|
prefix = [
|
||||||
|
"~/Code/"
|
||||||
|
]
|
||||||
|
exact = [
|
||||||
|
"~/.dotfiles/.envrc"
|
||||||
|
]
|
||||||
|
|
||||||
4
config/direnv/lib/use_asdf.sh
Normal file
4
config/direnv/lib/use_asdf.sh
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
### Do not edit. This was autogenerated by 'asdf direnv setup' ###
|
||||||
|
use_asdf() {
|
||||||
|
source_env "$(asdf direnv envrc "$@")"
|
||||||
|
}
|
||||||
517
config/exports
517
config/exports
@@ -1,34 +1,505 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
# shellcheck shell=zsh
|
# shellcheck shell=bash
|
||||||
# vim: filetype=zsh
|
# vim: filetype=zsh
|
||||||
|
|
||||||
export DOTFILES="$HOME/.dotfiles"
|
# Set XDG directories if not already set
|
||||||
source "$DOTFILES/scripts/shared.sh"
|
|
||||||
path_append "$DOTFILES/local/bin"
|
|
||||||
|
|
||||||
# Explicitly set XDG folders
|
|
||||||
# https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
|
# https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
|
||||||
export XDG_CONFIG_HOME="$HOME/.config"
|
[ -z "$XDG_CONFIG_HOME" ] && export XDG_CONFIG_HOME="$HOME/.config"
|
||||||
export XDG_DATA_HOME="$HOME/.local/share"
|
[ -z "$XDG_DATA_HOME" ] && export XDG_DATA_HOME="$HOME/.local/share"
|
||||||
export XDG_STATE_HOME="$HOME/.local/state"
|
[ -z "$XDG_CACHE_HOME" ] && export XDG_CACHE_HOME="$HOME/.cache"
|
||||||
|
[ -z "$XDG_STATE_HOME" ] && export XDG_STATE_HOME="$HOME/.local/state"
|
||||||
|
[ -z "$XDG_BIN_HOME" ] && export XDG_BIN_HOME="$HOME/.local/bin"
|
||||||
|
[ -z "$XDG_RUNTIME_DIR" ] && export XDG_RUNTIME_DIR="$HOME/.local/run"
|
||||||
|
|
||||||
# custom variables
|
# if DOTFILES is not set, set it to the default location
|
||||||
export XDG_BIN_HOME="$HOME/.local/bin"
|
[ -z "$DOTFILES" ] && export DOTFILES="$HOME/.dotfiles"
|
||||||
export XDG_CACHE_HOME="$HOME/.cache"
|
|
||||||
export XDG_RUNTIME_DIR="$HOME/.local/run"
|
|
||||||
|
|
||||||
path_append "/opt/homebrew/bin"
|
# zsh completions directory
|
||||||
have brew && eval "$(brew shellenv)"
|
[ -z "$ZSH_COMPLETIONS" ] && export ZSH_COMPLETIONS="$XDG_CONFIG_HOME/zsh/completion"
|
||||||
|
|
||||||
path_append "/usr/local/bin"
|
export PATH="$XDG_BIN_HOME:$DOTFILES/local/bin:$XDG_DATA_HOME/bob/nvim-bin:$XDG_DATA_HOME/cargo/bin:/opt/homebrew/bin:/usr/local/bin:$PATH"
|
||||||
path_append "$XDG_BIN_HOME"
|
|
||||||
|
|
||||||
# brew, https://brew.sh
|
# Add zsh completions to FPATH, compinit will be called later
|
||||||
have brew && {
|
FPATH="$ZSH_COMPLETIONS:$FPATH"
|
||||||
have_brew python && path_append "$(brew --prefix python)/bin"
|
|
||||||
|
if ! command -v msg &> /dev/null; then
|
||||||
|
# Function to print messages if VERBOSE is enabled
|
||||||
|
# $1 - message (string)
|
||||||
|
msg()
|
||||||
|
{
|
||||||
|
[[ $VERBOSE -eq 1 ]] && msgr msg "-> $1"
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Cache commands using bkt if installed
|
||||||
|
if command -v bkt &> /dev/null; then
|
||||||
|
bkt()
|
||||||
|
{
|
||||||
|
command bkt --cache-dir="$XDG_CACHE_HOME/bkt" "$@"
|
||||||
|
}
|
||||||
|
else
|
||||||
|
# If bkt isn't installed, skip its arguments and just execute directly.
|
||||||
|
# Optionally write a msg to stderr suggesting users install bkt.
|
||||||
|
bkt()
|
||||||
|
{
|
||||||
|
while [[ $1 == --* ]]; do shift; done
|
||||||
|
"$@"
|
||||||
|
}
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Shorthand for checking if the system has the bin in path,
|
||||||
|
# this version does not use caching.
|
||||||
|
# Usage: have_command php && php -v
|
||||||
|
have_command()
|
||||||
|
{
|
||||||
|
[ -z "$1" ] && {
|
||||||
|
echo "Usage: have_command <command>"
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
command -v "$1" &> /dev/null
|
||||||
}
|
}
|
||||||
|
|
||||||
source "$DOTFILES/config/exports-shell"
|
# Shorthand for checking if the system has the bin in path,
|
||||||
source "$DOTFILES/config/exports-apps"
|
# this version uses caching.
|
||||||
|
# Usage: have php && php -v
|
||||||
|
have()
|
||||||
|
{
|
||||||
|
bkt -- which "$1" &> /dev/null
|
||||||
|
}
|
||||||
|
|
||||||
have nvim && export EDITOR="nvim"
|
# Function to run dark-notify and change alacritty theme
|
||||||
|
# It uses flock to prevent running multiple instances.
|
||||||
|
# Install flock with `brew install flock` on macOS.
|
||||||
|
darknotify_alacritty()
|
||||||
|
{
|
||||||
|
x-have flock && [[ -f /tmp/dark-notify-alacritty.lock ]] && return
|
||||||
|
x-have dark-notify && {
|
||||||
|
# subprocess is used to prevent the command from showing it was backgrounded
|
||||||
|
(
|
||||||
|
flock /tmp/dark-notify-alacritty.lock dark-notify \
|
||||||
|
-c "$HOME/.dotfiles/local/bin/x-change-alacritty-theme" &
|
||||||
|
) &> /dev/null
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
# darknotify_alacritty
|
||||||
|
|
||||||
|
# Function to list installed Homebrew packages using bkt caching
|
||||||
|
brew_installed()
|
||||||
|
{
|
||||||
|
bkt -- brew list
|
||||||
|
}
|
||||||
|
|
||||||
|
# Shorthand for checking if a Homebrew package is installed
|
||||||
|
# Usage: have_brew php && php -v
|
||||||
|
have_brew()
|
||||||
|
{
|
||||||
|
! have brew && return 125
|
||||||
|
|
||||||
|
if bkt -- brew list "$1" &> /dev/null; then
|
||||||
|
return 0
|
||||||
|
else
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# Alacritty preexec hook to update dynamic title
|
||||||
|
preexec()
|
||||||
|
{
|
||||||
|
print -n -P "\e]0;$1%~\a"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Update dotfiles
|
||||||
|
dfu()
|
||||||
|
{
|
||||||
|
(
|
||||||
|
cd "$DOTFILES" && git rebase --ff --autostash && ./install
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
# Weather in Tampere, or other city
|
||||||
|
weather()
|
||||||
|
{
|
||||||
|
# https://github.com/chubin/wttr.in#usage
|
||||||
|
local city="${1:-Tampere}"
|
||||||
|
curl "http://wttr.in/${city// /+}?2nFQM&lang=fi"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Docker
|
||||||
|
ssh_docker()
|
||||||
|
{
|
||||||
|
docker exec -it "$@" bash
|
||||||
|
}
|
||||||
|
|
||||||
|
# Rector project to php version 8.2 by default.
|
||||||
|
rector()
|
||||||
|
{
|
||||||
|
local php="${1:-82}"
|
||||||
|
docker run -v "$(pwd)":/project rector/rector:latest process \
|
||||||
|
"/project/" \
|
||||||
|
--set "php${php}" \
|
||||||
|
--autoload-file /project/vendor/autoload.php
|
||||||
|
}
|
||||||
|
|
||||||
|
# Commit everything
|
||||||
|
commit()
|
||||||
|
{
|
||||||
|
local commitMessage="$*"
|
||||||
|
|
||||||
|
if [ -z "$commitMessage" ]; then
|
||||||
|
commitMessage="Automated commit"
|
||||||
|
fi
|
||||||
|
|
||||||
|
git add .
|
||||||
|
git commit -a -m "$commitMessage"
|
||||||
|
}
|
||||||
|
|
||||||
|
scheduler()
|
||||||
|
{
|
||||||
|
while :; do
|
||||||
|
php artisan schedule:run
|
||||||
|
echo "Sleeping 60 seconds..."
|
||||||
|
sleep 60
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
# Run command silently
|
||||||
|
# Usage: silent uptime
|
||||||
|
silent()
|
||||||
|
{
|
||||||
|
"$@" >&/dev/null
|
||||||
|
}
|
||||||
|
|
||||||
|
# Check if a file contains non-ascii characters
|
||||||
|
nonascii()
|
||||||
|
{
|
||||||
|
LC_ALL=C grep -n '[^[:print:][:space:]]' "${@}"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Remove non-ascii characters from string
|
||||||
|
# Usage: strip_nonascii "string"
|
||||||
|
strip_nonascii()
|
||||||
|
{
|
||||||
|
# shellcheck disable=SC2001
|
||||||
|
echo "$1" | LC_ALL=C sed 's/[^[:print:][:space:]]//g'
|
||||||
|
}
|
||||||
|
|
||||||
|
# Slugify a string
|
||||||
|
# Usage: slugify "string"
|
||||||
|
slugify()
|
||||||
|
{
|
||||||
|
echo "$1" | iconv -t ascii//TRANSLIT | sed -r s/[^a-zA-Z0-9]+/-/g | sed -r s/^-+\|-+$//g | tr '[:upper:]' '[:lower:]'
|
||||||
|
}
|
||||||
|
|
||||||
|
# https://stackoverflow.com/a/85932
|
||||||
|
fn_exists()
|
||||||
|
{
|
||||||
|
declare -f -F "$1" > /dev/null
|
||||||
|
return $?
|
||||||
|
}
|
||||||
|
|
||||||
|
# Creates a random string
|
||||||
|
rnd()
|
||||||
|
{
|
||||||
|
echo $RANDOM | md5sum | head -c 20
|
||||||
|
}
|
||||||
|
|
||||||
|
# return sha256sum for file
|
||||||
|
# $1 - filename (string)
|
||||||
|
get_sha256sum()
|
||||||
|
{
|
||||||
|
sha256sum "$1" | head -c 64
|
||||||
|
}
|
||||||
|
|
||||||
|
# Replaceable file
|
||||||
|
#
|
||||||
|
# $1 - filename (string)
|
||||||
|
# $2 - filename (string)
|
||||||
|
#
|
||||||
|
# Returns 1 when replaceable, 0 when not replaceable.
|
||||||
|
replacable()
|
||||||
|
{
|
||||||
|
FILE1="$1"
|
||||||
|
FILE2="$2"
|
||||||
|
|
||||||
|
[[ ! -r $FILE1 ]] && {
|
||||||
|
[[ $VERBOSE -eq 1 ]] && msgr err "File 1 ($FILE1) does not exist"
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
[[ ! -r $FILE2 ]] && {
|
||||||
|
[[ $VERBOSE -eq 1 ]] && msgr err "File 2 ($FILE2) does not exist, replaceable"
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
FILE1_HASH=$(get_sha256sum "$FILE1")
|
||||||
|
FILE2_HASH=$(get_sha256sum "$FILE2")
|
||||||
|
|
||||||
|
[[ $FILE1_HASH == "" ]] && {
|
||||||
|
[[ $VERBOSE -eq 1 ]] && msgr err "Could not get hash for file 1 ($FILE1)"
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
[[ $FILE2_HASH == "" ]] && {
|
||||||
|
[[ $VERBOSE -eq 1 ]] && msgr err "Could not get hash for file 2 ($FILE2), replaceable"
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
[[ $FILE1_HASH == "$FILE2_HASH" ]] && {
|
||||||
|
[[ $VERBOSE -eq 1 ]] && msgr ok "Files match, not replaceable: $FILE1"
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
[[ $VERBOSE -eq 1 ]] && msgr warn "Files do not match ($FILE1_HASH != $FILE2_HASH), replaceable"
|
||||||
|
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
export COMPLETION_WAITING_DOTS=true
|
||||||
|
|
||||||
|
# Bash completion file location
|
||||||
|
export BASH_COMPLETION_USER_FILE="${XDG_CONFIG_HOME}/bash-completion/bash_completion"
|
||||||
|
|
||||||
|
# History env variables
|
||||||
|
export HIST_STAMPS="yyyy-mm-dd"
|
||||||
|
export HISTFILE="${XDG_STATE_HOME}/zsh/history"
|
||||||
|
# Larger bash history (allow 32³ entries; default is 500)
|
||||||
|
export HISTSIZE=32768
|
||||||
|
export HISTFILESIZE=$HISTSIZE
|
||||||
|
# don't put duplicate lines or lines starting with space in the history.
|
||||||
|
# See bash(1) for more options
|
||||||
|
export HISTCONTROL=ignoreboth
|
||||||
|
# Make some commands not show up in history
|
||||||
|
export HISTIGNORE="ls:cd:cd -:pwd:exit:date:* --help"
|
||||||
|
# And include the parameter for ZSH
|
||||||
|
export HISTORY_IGNORE="(ls|cd|cd -|pwd|exit|date|* --help)"
|
||||||
|
|
||||||
|
# Less history location
|
||||||
|
export LESSHISTFILE="$XDG_STATE_HOME"/less/history
|
||||||
|
|
||||||
|
# Highlight section titles in manual pages
|
||||||
|
# export LESS_TERMCAP_md="$ORANGE"
|
||||||
|
|
||||||
|
# zsh autoloaded terminfo
|
||||||
|
# export TERMINFO="${XDG_DATA_HOME}/terminfo"
|
||||||
|
# export TERMINFO_DIRS="${XDG_DATA_HOME}/terminfo":/usr/share/terminfo
|
||||||
|
|
||||||
|
# Don't clear the screen after quitting a manual page
|
||||||
|
export MANPAGER="less -X"
|
||||||
|
|
||||||
|
# Always enable colored `grep` output
|
||||||
|
export GREP_OPTIONS="--color=auto"
|
||||||
|
|
||||||
|
# check the window size after each command and, if necessary,
|
||||||
|
# update the values of LINES and COLUMNS.
|
||||||
|
hash shopt 2> /dev/null && shopt -s checkwinsize
|
||||||
|
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
export SHORT_HOST=$(hostname -s)
|
||||||
|
|
||||||
|
# asdf
|
||||||
|
# https://github.com/asdf-vm/asdf
|
||||||
|
msg "Setting up asdf configuration"
|
||||||
|
export ASDF_DIR="${XDG_BIN_HOME}/asdf"
|
||||||
|
if [[ -d $ASDF_DIR ]]; then
|
||||||
|
[[ -d $ASDF_DIR/completions ]] && FPATH="$ASDF_DIR/completions:$FPATH"
|
||||||
|
[[ -d $ASDF_DIR/plugins ]] && FPATH="$ASDF_DIR/plugins:$FPATH"
|
||||||
|
|
||||||
|
export ASDF_CONFIG_FILE="${XDG_CONFIG_HOME}/asdf/asdfrc"
|
||||||
|
export ASDF_DATA_DIR="${ASDF_DIR}"
|
||||||
|
export ASDF_PLUGIN_MANAGER_PLUGIN_VERSIONS_FILENAME="${XDG_CONFIG_HOME}/asdf/plugin-versions"
|
||||||
|
export ASDF_LOG_FILE="${XDG_CACHE_HOME}/asdf/asdf.log"
|
||||||
|
export ASDF_FORCE_PREPEND=yes
|
||||||
|
## Default package files
|
||||||
|
export ASDF_CRATE_DEFAULT_PACKAGES_FILE="${XDG_CONFIG_HOME}/asdf/cargo-packages"
|
||||||
|
export ASDF_GEM_DEFAULT_PACKAGES_FILE="${XDG_CONFIG_HOME}/asdf/gem-packages"
|
||||||
|
export ASDF_GOLANG_DEFAULT_PACKAGES_FILE="${XDG_CONFIG_HOME}/asdf/golang-packages"
|
||||||
|
export ASDF_NPM_DEFAULT_PACKAGES_FILE="${XDG_CONFIG_HOME}/asdf/npm-packages"
|
||||||
|
export ASDF_PYTHON_DEFAULT_PACKAGES_FILE="${XDG_CONFIG_HOME}/asdf/python-packages"
|
||||||
|
## Plugin configuration
|
||||||
|
export ASDF_DIRENV_IGNORE_MISSING_PLUGINS=1
|
||||||
|
export ASDF_GOLANG_MOD_VERSION_ENABLED=true
|
||||||
|
export ASDF_NODEJS_LEGACY_FILE_DYNAMIC_STRATEGY="latest_available"
|
||||||
|
## Add asdf to path
|
||||||
|
export PATH="${ASDF_DIR}/bin:${PATH}"
|
||||||
|
|
||||||
|
source "$ASDF_DIR/asdf.sh"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Antidote configuration
|
||||||
|
# https://getantidote.github.io/
|
||||||
|
msg "Setting up Antidote configuration"
|
||||||
|
export ANTIDOTE_DIR="$DOTFILES/tools/antidote"
|
||||||
|
export ANTIDOTE_HOME="$XDG_CACHE_HOME/antidote"
|
||||||
|
export ANTIDOTE_PLUGINS="$XDG_CONFIG_HOME/zsh/antidote_plugins"
|
||||||
|
|
||||||
|
# Ansible configuration
|
||||||
|
# https://docs.ansible.com/ansible/latest/reference_appendices/config.html
|
||||||
|
msg "Setting up Ansible configuration"
|
||||||
|
export ANSIBLE_HOME="$XDG_CONFIG_HOME/ansible"
|
||||||
|
export ANSIBLE_CONFIG="$XDG_CONFIG_HOME/ansible.cfg"
|
||||||
|
export ANSIBLE_GALAXY_CACHE_DIR="$XDG_CACHE_HOME/ansible/galaxy_cache"
|
||||||
|
x-dc "$ANSIBLE_HOME"
|
||||||
|
x-dc "$ANSIBLE_GALAXY_CACHE_DIR"
|
||||||
|
|
||||||
|
# aws
|
||||||
|
# https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html
|
||||||
|
# https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-envvars.html
|
||||||
|
# https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-profiles.html
|
||||||
|
msg "Setting up AWS configuration"
|
||||||
|
export AWS_CONFIG_FILE="${XDG_STATE_HOME}/aws/config"
|
||||||
|
export AWS_SHARED_CREDENTIALS_FILE="${XDG_STATE_HOME}/aws/credentials"
|
||||||
|
export AWS_DATA_PATH="${XDG_DATA_HOME}/aws"
|
||||||
|
export AWS_DEFAULT_REGION="eu-west-1"
|
||||||
|
export AWS_DEFAULT_OUTPUT="table"
|
||||||
|
export AWS_CONFIGURE_KEYS=true
|
||||||
|
export AWS_CONFIGURE_REGION=true
|
||||||
|
export AWS_CONFIGURE_OUTPUT=true
|
||||||
|
export AWS_CONFIGURE_PROFILE=true
|
||||||
|
export AWS_CONFIGURE_PROMPT=true
|
||||||
|
export AWS_CONFIGURE_PROMPT_DEFAULT="default"
|
||||||
|
|
||||||
|
# bob manages nvim versions
|
||||||
|
msg "Setting up bob configuration"
|
||||||
|
x-path-prepend "$XDG_DATA_HOME/bob/nvim-bin"
|
||||||
|
|
||||||
|
# bkt (shell command caching tool) configuration
|
||||||
|
msg "Setting up bkt configuration"
|
||||||
|
export BKT_TTL=1m
|
||||||
|
|
||||||
|
# brew, https://docs.brew.sh/Manpage
|
||||||
|
msg "Setting up Homebrew configuration"
|
||||||
|
export HOMEBREW_NO_ANALYTICS=true
|
||||||
|
export HOMEBREW_NO_ENV_HINTS=true
|
||||||
|
export HOMEBREW_BUNDLE_MAS_SKIP=true
|
||||||
|
export HOMEBREW_BUNDLE_FILE="$XDG_CONFIG_HOME/homebrew/Brewfile"
|
||||||
|
x-have brew && {
|
||||||
|
# Add brew autocompletion to fpath
|
||||||
|
FPATH="$(brew --prefix)/share/zsh/site-functions:${FPATH}"
|
||||||
|
eval "$(brew shellenv)"
|
||||||
|
}
|
||||||
|
|
||||||
|
# composer, https://getcomposer.org/
|
||||||
|
msg "Setting up Composer configuration"
|
||||||
|
export COMPOSER_HOME="$XDG_STATE_HOME/composer"
|
||||||
|
export COMPOSER_BIN="$COMPOSER_HOME/vendor/bin"
|
||||||
|
export PATH="$COMPOSER_BIN:$PATH"
|
||||||
|
|
||||||
|
# direnv, https://direnv.net/
|
||||||
|
# https://direnv.net/docs/hook.html
|
||||||
|
# Set the hook to show the direnv message in a different color
|
||||||
|
# export DIRENV_LOG_FORMAT=$'\033[2mdirenv: %s\033[0m'
|
||||||
|
export DIRENV_LOG_FORMAT=
|
||||||
|
|
||||||
|
# docker, https://docs.docker.com/engine/reference/commandline/cli/
|
||||||
|
msg "Setting up Docker configuration"
|
||||||
|
export DOCKER_CONFIG="${XDG_CONFIG_HOME}/docker"
|
||||||
|
x-dc "$DOCKER_CONFIG"
|
||||||
|
# Docker: Disable snyk ad
|
||||||
|
export DOCKER_SCAN_SUGGEST=false
|
||||||
|
|
||||||
|
# fzf
|
||||||
|
export FZF_BASE="${XDG_CONFIG_HOME}/fzf"
|
||||||
|
export FZF_DEFAULT_OPTS='--height 40% --tmux bottom,40% --layout reverse --border top'
|
||||||
|
|
||||||
|
# GnuPG
|
||||||
|
# https://gnupg.org/documentation/manuals/gnupg/Invoking-GPG.html
|
||||||
|
msg "Setting up GnuPG configuration"
|
||||||
|
export GNUPGHOME="${XDG_DATA_HOME}/gnupg"
|
||||||
|
|
||||||
|
# Go
|
||||||
|
# https://golang.org/doc/code.html
|
||||||
|
msg "Setting up Go configuration"
|
||||||
|
export GOPATH="$XDG_DATA_HOME/go"
|
||||||
|
export GOBIN="$XDG_BIN_HOME"
|
||||||
|
|
||||||
|
# Lando
|
||||||
|
export PATH="$HOME/.lando/bin${PATH+:$PATH}" #landopath
|
||||||
|
|
||||||
|
# NPM: Add npm packages to path
|
||||||
|
msg "Setting up NPM configuration"
|
||||||
|
x-have node && {
|
||||||
|
NVM_NODE_BIN_DIR="$(dirname "$(which node)")"
|
||||||
|
export PATH="$NVM_NODE_BIN_DIR:$PATH"
|
||||||
|
}
|
||||||
|
|
||||||
|
# oh-my-posh (omp) configuration
|
||||||
|
msg "Setting up oh-my-posh configuration"
|
||||||
|
export OHMYPOSH_CFG="$DOTFILES/config/omp/own.toml"
|
||||||
|
|
||||||
|
# op (1Password cli) is present
|
||||||
|
msg "Setting up 1Password CLI configuration"
|
||||||
|
export OP_CACHE="$XDG_STATE_HOME/1password"
|
||||||
|
|
||||||
|
# Python
|
||||||
|
#
|
||||||
|
# pyenv, python environments
|
||||||
|
msg "Setting up Python configuration"
|
||||||
|
export WORKON_HOME="$XDG_DATA_HOME/virtualenvs"
|
||||||
|
export PYENV_ROOT="$XDG_STATE_HOME/pyenv"
|
||||||
|
## for MichaelAquilina/zsh-autoswitch-virtualenv
|
||||||
|
export AUTOSWITCH_VIRTUAL_ENV_DIR="$WORKON_HOME"
|
||||||
|
export PATH="$PYENV_ROOT/bin:$PYENV_ROOT/shims:$PATH"
|
||||||
|
[[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH"
|
||||||
|
x-have pyenv && eval "$(pyenv init -)"
|
||||||
|
|
||||||
|
# Rust / cargo
|
||||||
|
msg "Setting up Rust/Cargo configuration"
|
||||||
|
export RUST_WITHOUT=rust-docs
|
||||||
|
|
||||||
|
# screen
|
||||||
|
# https://www.gnu.org/software/screen/manual/screen.html
|
||||||
|
msg "Setting up screen configuration"
|
||||||
|
export SCREENRC="$XDG_CONFIG_HOME/misc/screenrc"
|
||||||
|
|
||||||
|
# sonarlint
|
||||||
|
# https://www.sonarlint.org/
|
||||||
|
msg "Setting up Sonarlint configuration"
|
||||||
|
export SONARLINT_USER_HOME="$XDG_DATA_HOME/sonarlint"
|
||||||
|
|
||||||
|
# terraform
|
||||||
|
# https://www.terraform.io/docs/cli/config/config-file.html
|
||||||
|
# https://www.terraform.io/docs/cli/config/environment-variables.html
|
||||||
|
msg "Setting up Terraform configuration"
|
||||||
|
export TF_DATA_DIR="$XDG_STATE_HOME/terraform"
|
||||||
|
export TF_CLI_CONFIG_FILE="$XDG_CONFIG_HOME/terraform/terraformrc"
|
||||||
|
export TF_PLUGIN_CACHE_DIR="$XDG_CACHE_HOME/terraform/plugin-cache"
|
||||||
|
|
||||||
|
# tmux
|
||||||
|
# https://tmux.github.io/
|
||||||
|
msg "Setting up tmux configuration"
|
||||||
|
export TMUX_TMPDIR="$XDG_STATE_HOME/tmux"
|
||||||
|
export TMUX_CONF_DIR="$XDG_CONFIG_HOME/tmux"
|
||||||
|
export TMUX_PLUGINS="$TMUX_CONF_DIR/plugins"
|
||||||
|
export TMUX_CONF="$TMUX_CONF_DIR/tmux.conf"
|
||||||
|
## These settings are for zsh-tmux
|
||||||
|
export ZSH_TMUX_AUTOSTART=false
|
||||||
|
export ZSH_TMUX_CONFIG="$TMUX_CONF"
|
||||||
|
export ZSH_TMUX_UNICODE=true
|
||||||
|
export ZSH_TMUX_AUTOQUIT=false
|
||||||
|
export ZSH_TMUX_DEFAULT_SESSION_NAME=main
|
||||||
|
|
||||||
|
# tms, https://github.com/jrmoulton/tmux-sessionizer
|
||||||
|
export TMS_CONFIG_FILE="${XDG_CONFIG_HOME}/tms/config.toml"
|
||||||
|
|
||||||
|
# wakatime, https://github.com/wakatime/wakatime-cli
|
||||||
|
msg "Setting up Wakatime configuration"
|
||||||
|
export WAKATIME_HOME="$XDG_STATE_HOME/wakatime"
|
||||||
|
x-dc "$WAKATIME_HOME"
|
||||||
|
|
||||||
|
# Misc
|
||||||
|
msg "Setting up miscellaneous configuration"
|
||||||
|
export ZSHZ_DATA="$XDG_STATE_HOME/z"
|
||||||
|
export CHEAT_USE_FZF=true
|
||||||
|
export SQLITE_HISTORY="${XDG_CACHE_HOME}/sqlite_history"
|
||||||
|
|
||||||
|
X_EXPORTS_FILES=(
|
||||||
|
"$HOME/.config/exports-secret"
|
||||||
|
"$HOME/.config/exports-$(hostname)"
|
||||||
|
"$HOME/.config/exports-$(hostname)-secret"
|
||||||
|
)
|
||||||
|
for exportFile in "${X_EXPORTS_FILES[@]}"; do
|
||||||
|
# shellcheck source=$HOME/.config/exports-secret
|
||||||
|
[ -f "$exportFile" ] && source "$exportFile" && msg "Sourced $exportFile"
|
||||||
|
done
|
||||||
|
unset X_EXPORTS_FILES
|
||||||
|
|||||||
@@ -1,148 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
# shellcheck shell=bash
|
|
||||||
# shellcheck enable=external-sources
|
|
||||||
# shellcheck disable=1091,2139
|
|
||||||
# vim: filetype=zsh
|
|
||||||
export DOTFILES="$HOME/.dotfiles"
|
|
||||||
source "$DOTFILES/scripts/shared.sh"
|
|
||||||
|
|
||||||
# Antigen configuration
|
|
||||||
# https://github.com/zsh-users/antigen/wiki/Configuration
|
|
||||||
export ADOTDIR="$XDG_DATA_HOME/antigen"
|
|
||||||
export ANTIGEN_SYSTEM_RECEIPT_F=".local/share/antigen/antigen_system_lastupdate"
|
|
||||||
export ANTIGEN_PLUGIN_RECEIPT_F=".local/share/antigen/antigen_plugin_lastupdate"
|
|
||||||
|
|
||||||
# Ansible configuration
|
|
||||||
# https://docs.ansible.com/ansible/latest/reference_appendices/config.html
|
|
||||||
export ANSIBLE_HOME="$XDG_CONFIG_HOME/ansible"
|
|
||||||
export ANSIBLE_CONFIG="$XDG_CONFIG_HOME/ansible.cfg"
|
|
||||||
export ANSIBLE_GALAXY_CACHE_DIR="$XDG_CACHE_HOME/ansible/galaxy_cache"
|
|
||||||
have ansible && {
|
|
||||||
x-dc "$ANSIBLE_HOME"
|
|
||||||
x-dc "$ANSIBLE_GALAXY_CACHE_DIR"
|
|
||||||
}
|
|
||||||
|
|
||||||
export ANDROID_HOME="$XDG_DATA_HOME/android"
|
|
||||||
|
|
||||||
export HOMEBREW_NO_ENV_HINTS=true
|
|
||||||
|
|
||||||
# composer, https://getcomposer.org/
|
|
||||||
export COMPOSER_HOME="$XDG_STATE_HOME/composer"
|
|
||||||
export COMPOSER_BIN="$COMPOSER_HOME/vendor/bin"
|
|
||||||
have composer && {
|
|
||||||
export PATH="$COMPOSER_BIN:$PATH"
|
|
||||||
}
|
|
||||||
|
|
||||||
# docker, https://docs.docker.com/engine/reference/commandline/cli/
|
|
||||||
export DOCKER_CONFIG="$XDG_CONFIG_HOME/docker"
|
|
||||||
have docker && {
|
|
||||||
x-dc "$DOCKER_CONFIG"
|
|
||||||
# Docker: Disable snyk ad
|
|
||||||
export DOCKER_SCAN_SUGGEST=false
|
|
||||||
}
|
|
||||||
|
|
||||||
# ffmpeg
|
|
||||||
export FFMPEG_DATADIR="$XDG_CONFIG_HOME/ffmpeg"
|
|
||||||
have ffmpeg && x-dc "$FFMPEG_DATADIR"
|
|
||||||
|
|
||||||
# gcloud
|
|
||||||
have gcloud && {
|
|
||||||
GCLOUD_LOC=$(gcloud info --format="value(installation.sdk_root)" --quiet)
|
|
||||||
[[ -f "$GCLOUD_LOC/path.zsh.inc" ]] && builtin source "$GCLOUD_LOC/path.zsh.inc"
|
|
||||||
[[ -f "$GCLOUD_LOC/completion.zsh.inc" ]] && builtin source "$GCLOUD_LOC/completion.zsh.inc"
|
|
||||||
}
|
|
||||||
|
|
||||||
# GnuPG
|
|
||||||
export GNUPGHOME="$XDG_DATA_HOME/gnupg"
|
|
||||||
|
|
||||||
# Go
|
|
||||||
export GOPATH="$XDG_DATA_HOME/go"
|
|
||||||
export GOBIN="$XDG_BIN_HOME"
|
|
||||||
|
|
||||||
# irssi
|
|
||||||
have irssi && {
|
|
||||||
# These variables are used in ./alias with --config and --home
|
|
||||||
export IRSSI_CONFIG_HOME="$XDG_CONFIG_HOME/irssi"
|
|
||||||
export IRSSI_CONFIG_FILE="$IRSSI_CONFIG_HOME/config"
|
|
||||||
x-dc "$IRSSI_CONFIG_HOME"
|
|
||||||
}
|
|
||||||
|
|
||||||
# nb, https://xwmx.github.io/nb/
|
|
||||||
export NBRC_PATH="$XDG_CONFIG_HOME/nbrc"
|
|
||||||
export NB_DIR="$XDG_STATE_HOME/nb"
|
|
||||||
|
|
||||||
# nvm, the node version manager
|
|
||||||
export NVM_LAZY_LOAD=true
|
|
||||||
export NVM_COMPLETION=true
|
|
||||||
export NVM_AUTO_USE=true
|
|
||||||
export NVM_DIR="$XDG_CONFIG_HOME/nvm"
|
|
||||||
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
|
|
||||||
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
|
||||||
|
|
||||||
export NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME"/npm/npmrc
|
|
||||||
|
|
||||||
# Add npm packages to path
|
|
||||||
have node && {
|
|
||||||
NVM_NODE_BIN_DIR="$(dirname "$(which node)")"
|
|
||||||
path_append "$NVM_NODE_BIN_DIR"
|
|
||||||
}
|
|
||||||
|
|
||||||
# op (1Password cli) is present
|
|
||||||
export OP_CACHE="$XDG_STATE_HOME/1password"
|
|
||||||
have op && {
|
|
||||||
eval "$(op completion zsh)"
|
|
||||||
compdef _op op
|
|
||||||
}
|
|
||||||
|
|
||||||
# Python
|
|
||||||
#
|
|
||||||
# pyenv, python environments
|
|
||||||
export WORKON_HOME="$XDG_DATA_HOME/virtualenvs"
|
|
||||||
export PYENV_ROOT="$XDG_STATE_HOME/pyenv"
|
|
||||||
have pyenv && {
|
|
||||||
path_append "$(pyenv root)/shims"
|
|
||||||
path_append "$PYENV_ROOT/bin"
|
|
||||||
eval "$(pyenv init -)"
|
|
||||||
}
|
|
||||||
|
|
||||||
# Ruby
|
|
||||||
#
|
|
||||||
# including: bundler, rbenv
|
|
||||||
export GEM_HOME="${XDG_DATA_HOME}"/gem
|
|
||||||
export GEM_SPEC_CACHE="${XDG_CACHE_HOME}"/gem
|
|
||||||
export BUNDLE_USER_CONFIG="$XDG_CONFIG_HOME"/bundle
|
|
||||||
export BUNDLE_USER_CACHE="$XDG_CACHE_HOME"/bundle
|
|
||||||
export BUNDLE_USER_PLUGIN="$XDG_DATA_HOME"/bundle
|
|
||||||
export RBENV_ROOT="$XDG_STATE_HOME/rbenv"
|
|
||||||
x-dc "$RBENV_ROOT"
|
|
||||||
have gem && path_append "$(gem environment gemdir)/bin"
|
|
||||||
have rbenv && eval "$(rbenv init - zsh)"
|
|
||||||
|
|
||||||
# Rust / cargo
|
|
||||||
export CARGO_HOME="$XDG_DATA_HOME/cargo"
|
|
||||||
path_append "$CARGO_HOME/bin"
|
|
||||||
|
|
||||||
# screen
|
|
||||||
export SCREENRC="$XDG_CONFIG_HOME/misc/screenrc"
|
|
||||||
|
|
||||||
# sonarlint
|
|
||||||
export SONARLINT_USER_HOME="$XDG_DATA_HOME/sonarlint"
|
|
||||||
|
|
||||||
# tldr / tealdeer
|
|
||||||
export TEALDEER_CONFIG_DIR="$XDG_CONFIG_HOME/tealdeer/"
|
|
||||||
|
|
||||||
# tmux
|
|
||||||
export TMUX_CONF="$XDG_CONFIG_HOME/tmux/tmux.conf"
|
|
||||||
|
|
||||||
# wakatime, https://github.com/wakatime/wakatime-cli
|
|
||||||
export WAKATIME_HOME="$XDG_STATE_HOME/wakatime"
|
|
||||||
x-dc "$WAKATIME_HOME"
|
|
||||||
|
|
||||||
# z, https://github.com/rupa/z
|
|
||||||
export _Z_DATA="$XDG_STATE_HOME/z"
|
|
||||||
[[ -f "$XDG_BIN_HOME/z/z.sh" ]] && source "$XDG_BIN_HOME/z/z.sh"
|
|
||||||
|
|
||||||
# Misc
|
|
||||||
export BAT_THEME="ansi"
|
|
||||||
export CHEAT_USE_FZF=true
|
|
||||||
export SQLITE_HISTORY="$XDG_CACHE_HOME"/sqlite_history
|
|
||||||
25
config/exports-lakka
Normal file
25
config/exports-lakka
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
# lakka exports
|
||||||
|
|
||||||
|
## LUA
|
||||||
|
if command -v luarocks &> /dev/null; then
|
||||||
|
eval "$(luarocks path --bin)"
|
||||||
|
fi
|
||||||
|
|
||||||
|
export PATH="$HOME/.local/go/bin:$PATH"
|
||||||
|
|
||||||
|
alias logrotate='/usr/sbin/logrotate -s "$HOME/logs/state"'
|
||||||
|
alias nano='nano -wS -$'
|
||||||
|
alias gpg=gpg2
|
||||||
|
|
||||||
|
ACME_PATH="$HOME/.acme.sh"
|
||||||
|
# shellcheck source=$HOME/.acme.sh/acme.sh.env
|
||||||
|
if [[ -s "$ACME_PATH/acme.sh.env" ]]; then
|
||||||
|
source "$ACME_PATH/acme.sh.env"
|
||||||
|
fi
|
||||||
|
|
||||||
|
export RVM_PATH="$HOME/.rvm"
|
||||||
|
export PATH="$RVM_PATH/bin:$PATH"
|
||||||
|
# shellcheck source=$HOME/.rvm/scripts/rvm
|
||||||
|
if [[ -s "$RVM_PATH/scripts/rvm" ]]; then
|
||||||
|
source "$RVM_PATH/scripts/rvm" # Load RVM into a shell session *as a function*
|
||||||
|
fi
|
||||||
@@ -1,64 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
# shellcheck shell=bash
|
|
||||||
# shellcheck disable=1091,2046
|
|
||||||
# vim: filetype=zsh
|
|
||||||
export DOTFILES="$HOME/.dotfiles"
|
|
||||||
source "$DOTFILES/scripts/shared.sh"
|
|
||||||
|
|
||||||
export LC_ALL=fi_FI.UTF-8
|
|
||||||
|
|
||||||
# Bash completion file location
|
|
||||||
export BASH_COMPLETION_USER_FILE="${XDG_CONFIG_HOME}/bash-completion/bash_completion"
|
|
||||||
|
|
||||||
# History env variables
|
|
||||||
export HIST_STAMPS="yyyy-mm-dd"
|
|
||||||
# Larger bash history (allow 32³ entries; default is 500)
|
|
||||||
export HISTSIZE=32768
|
|
||||||
export HISTFILESIZE=$HISTSIZE
|
|
||||||
# don't put duplicate lines or lines starting with space in the history.
|
|
||||||
# See bash(1) for more options
|
|
||||||
export HISTCONTROL=ignoreboth
|
|
||||||
# Make some commands not show up in history
|
|
||||||
export HISTIGNORE="ls:cd:cd -:pwd:exit:date:* --help"
|
|
||||||
# And include the parameter for ZSH
|
|
||||||
export HISTORY_IGNORE="(ls|cd|cd -|pwd|exit|date|* --help)"
|
|
||||||
|
|
||||||
# Highlight section titles in manual pages
|
|
||||||
export LESS_TERMCAP_md="$ORANGE"
|
|
||||||
|
|
||||||
# Don’t clear the screen after quitting a manual page
|
|
||||||
export MANPAGER="less -X"
|
|
||||||
|
|
||||||
# Always enable colored `grep` output
|
|
||||||
export GREP_OPTIONS="--color=auto"
|
|
||||||
|
|
||||||
# check the window size after each command and, if necessary,
|
|
||||||
# update the values of LINES and COLUMNS.
|
|
||||||
hash shopt 2> /dev/null && shopt -s checkwinsize
|
|
||||||
|
|
||||||
# Load iterm2 shell integration
|
|
||||||
# https://iterm2.com/documentation-shell-integration.html
|
|
||||||
[[ -f "$XDG_BIN_HOME/iterm2_shell_integration.zsh" ]] \
|
|
||||||
&& source "$XDG_BIN_HOME/iterm2_shell_integration.zsh"
|
|
||||||
|
|
||||||
# Set dircolors based on the file, if it exists
|
|
||||||
have dircolors && eval $(dircolors "$XDG_CONFIG_HOME/dircolors")
|
|
||||||
|
|
||||||
# If we are using zsh, color our dir lists and such
|
|
||||||
if [ "$SHELL" = "$(which zsh)" ]; then
|
|
||||||
x-dc "$XDG_CACHE_HOME/zsh"
|
|
||||||
x-dc "$XDG_STATE_HOME/zsh"
|
|
||||||
export HISTFILE="$XDG_STATE_HOME/zsh/history"
|
|
||||||
zstyle ':completion:*' cache-path "$XDG_CACHE_HOME/zsh/zcompcache"
|
|
||||||
zstyle ':completion:*' list-colors "$LS_COLORS"
|
|
||||||
|
|
||||||
# fzf
|
|
||||||
[ -f "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.zsh ] \
|
|
||||||
&& source "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.zsh
|
|
||||||
fi
|
|
||||||
|
|
||||||
# If we are using bash
|
|
||||||
if [ "$SHELL" = "$(which bash)" ]; then
|
|
||||||
[ -f "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.bash ] \
|
|
||||||
&& source "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.bash
|
|
||||||
fi
|
|
||||||
@@ -1,89 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
#
|
|
||||||
# shell functions
|
|
||||||
#
|
|
||||||
# shellcheck source="../scripts/shared.sh"
|
|
||||||
export DOTFILES="$HOME/.dotfiles"
|
|
||||||
source "$DOTFILES/scripts/shared.sh"
|
|
||||||
|
|
||||||
# Weather in Tampere, or other city
|
|
||||||
weather()
|
|
||||||
{
|
|
||||||
# https://github.com/chubin/wttr.in#usage
|
|
||||||
local city="${1:-Tampere}"
|
|
||||||
curl "http://wttr.in/${city// /+}?2nFQM&lang=fi"
|
|
||||||
}
|
|
||||||
|
|
||||||
# Docker
|
|
||||||
ssh-docker()
|
|
||||||
{
|
|
||||||
docker exec -it "$@" bash
|
|
||||||
}
|
|
||||||
|
|
||||||
# All the dig info
|
|
||||||
digga()
|
|
||||||
{
|
|
||||||
dig +nocmd "$1" any +multiline +noall +answer
|
|
||||||
}
|
|
||||||
|
|
||||||
# Rector project to php version 8.2 by default.
|
|
||||||
rector()
|
|
||||||
{
|
|
||||||
local php="${1:-82}"
|
|
||||||
docker run -v "$(pwd)":/project rector/rector:latest process \
|
|
||||||
"/project/$1" \
|
|
||||||
--set "php${php}" \
|
|
||||||
--autoload-file /project/vendor/autoload.php
|
|
||||||
}
|
|
||||||
|
|
||||||
# Commit everything
|
|
||||||
commit()
|
|
||||||
{
|
|
||||||
commitMessage="$*"
|
|
||||||
|
|
||||||
if [ "$commitMessage" = "" ]; then
|
|
||||||
commitMessage="Automated commit"
|
|
||||||
fi
|
|
||||||
|
|
||||||
git add .
|
|
||||||
eval "git commit -a -m '${commitMessage}'"
|
|
||||||
}
|
|
||||||
|
|
||||||
scheduler()
|
|
||||||
{
|
|
||||||
while :; do
|
|
||||||
php artisan schedule:run
|
|
||||||
echo "Sleeping 60 seconds..."
|
|
||||||
sleep 60
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
# Defines default antigen bundles
|
|
||||||
x-default-antigen-bundles()
|
|
||||||
{
|
|
||||||
export ZSH_TMUX_AUTOSTART=true
|
|
||||||
export ZSH_TMUX_CONFIG="$DOTFILES/config/tmux/tmux.conf"
|
|
||||||
export ZSH_TMUX_UNICODE=true
|
|
||||||
|
|
||||||
# these should be always available
|
|
||||||
antigen bundle tmux
|
|
||||||
antigen bundle colored-man-pages
|
|
||||||
antigen bundle command-not-found
|
|
||||||
antigen bundle ssh-agent
|
|
||||||
# antigen bundle MichaelAquilina/zsh-you-should-use
|
|
||||||
antigen bundle jreese/zsh-titles
|
|
||||||
antigen bundle unixorn/autoupdate-antigen.zshplugin
|
|
||||||
antigen bundle zsh-users/zsh-completions
|
|
||||||
antigen bundle zsh-users/zsh-syntax-highlighting
|
|
||||||
|
|
||||||
# these should be available if there's need
|
|
||||||
have brew && antigen bundle brew
|
|
||||||
have nvm && antigen bundle nvm
|
|
||||||
have nvm && antigen bundle "$DOTFILES/config/zsh/plugins/nvm-auto-use"
|
|
||||||
have php && antigen bundle php
|
|
||||||
have python && antigen bundle MichaelAquilina/zsh-autoswitch-virtualenv
|
|
||||||
have rvm && antigen bundle unixorn/rvm-plugin
|
|
||||||
|
|
||||||
# the theme to use
|
|
||||||
antigen theme romkatv/powerlevel10k
|
|
||||||
}
|
|
||||||
20
config/gh-changelog/config.yaml
Normal file
20
config/gh-changelog/config.yaml
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
---
|
||||||
|
check_for_updates: true
|
||||||
|
excluded_labels:
|
||||||
|
- maintenance
|
||||||
|
- dependencies
|
||||||
|
file_name: CHANGELOG.md
|
||||||
|
logger: spinner
|
||||||
|
no_color: false
|
||||||
|
sections:
|
||||||
|
added:
|
||||||
|
- feature
|
||||||
|
- enhancement
|
||||||
|
changed:
|
||||||
|
- backwards-incompatible
|
||||||
|
fixed:
|
||||||
|
- bug
|
||||||
|
- bugfix
|
||||||
|
- documentation
|
||||||
|
show_unreleased: true
|
||||||
|
skip_entries_without_label: false
|
||||||
54
config/gh-dash/config.yml
Normal file
54
config/gh-dash/config.yml
Normal file
@@ -0,0 +1,54 @@
|
|||||||
|
prSections:
|
||||||
|
- title: My Pull Requests
|
||||||
|
filters: is:open author:@me
|
||||||
|
- title: Needs My Review
|
||||||
|
filters: is:open review-requested:@me
|
||||||
|
- title: Involved
|
||||||
|
filters: is:open involves:@me -author:@me
|
||||||
|
issuesSections:
|
||||||
|
- title: My Issues
|
||||||
|
filters: is:open author:@me
|
||||||
|
- title: Assigned
|
||||||
|
filters: is:open assignee:@me
|
||||||
|
- title: Involved
|
||||||
|
filters: is:open involves:@me -author:@me
|
||||||
|
defaults:
|
||||||
|
preview:
|
||||||
|
open: true
|
||||||
|
width: 50
|
||||||
|
prsLimit: 20
|
||||||
|
issuesLimit: 20
|
||||||
|
view: prs
|
||||||
|
layout:
|
||||||
|
prs:
|
||||||
|
updatedAt:
|
||||||
|
width: 7
|
||||||
|
repo:
|
||||||
|
width: 15
|
||||||
|
author:
|
||||||
|
width: 15
|
||||||
|
assignees:
|
||||||
|
width: 20
|
||||||
|
hidden: true
|
||||||
|
base:
|
||||||
|
width: 15
|
||||||
|
hidden: true
|
||||||
|
lines:
|
||||||
|
width: 16
|
||||||
|
issues:
|
||||||
|
updatedAt:
|
||||||
|
width: 7
|
||||||
|
repo:
|
||||||
|
width: 15
|
||||||
|
creator:
|
||||||
|
width: 10
|
||||||
|
assignees:
|
||||||
|
width: 20
|
||||||
|
hidden: true
|
||||||
|
refetchIntervalMinutes: 30
|
||||||
|
keybindings:
|
||||||
|
issues: []
|
||||||
|
prs: []
|
||||||
|
repoPaths: {}
|
||||||
|
pager:
|
||||||
|
diff: ''
|
||||||
@@ -1 +1,3 @@
|
|||||||
|
---
|
||||||
git_protocol: https
|
git_protocol: https
|
||||||
|
version: '1'
|
||||||
|
|||||||
6
config/gh/hosts.yml
Normal file
6
config/gh/hosts.yml
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
---
|
||||||
|
github.com:
|
||||||
|
git_protocol: https
|
||||||
|
users:
|
||||||
|
ivuorinen:
|
||||||
|
user: ivuorinen
|
||||||
15
config/ghostty/config
Normal file
15
config/ghostty/config
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# vim: ft=ghostty
|
||||||
|
theme = "light:tokyonight-day,dark:tokyonight-storm"
|
||||||
|
font-family = "JetBrainsMono Nerd Font Mono"
|
||||||
|
|
||||||
|
background-blur-radius = 15
|
||||||
|
background-opacity = 0.95
|
||||||
|
|
||||||
|
clipboard-read = allow
|
||||||
|
clipboard-write = allow
|
||||||
|
cursor-style = bar
|
||||||
|
custom-shader-animation = true
|
||||||
|
gtk-single-instance = true
|
||||||
|
mouse-hide-while-typing = true
|
||||||
|
shell-integration-features = true
|
||||||
|
window-theme = system
|
||||||
@@ -5,3 +5,11 @@
|
|||||||
name = Ismo Vuorinen
|
name = Ismo Vuorinen
|
||||||
email = ismo@ivuorinen.net
|
email = ismo@ivuorinen.net
|
||||||
|
|
||||||
|
[github]
|
||||||
|
user = ivuorinen
|
||||||
|
|
||||||
|
[include]
|
||||||
|
path = ~/.config/git/overrides/config
|
||||||
|
|
||||||
|
[advice]
|
||||||
|
detachedHead = false
|
||||||
|
|||||||
@@ -18,3 +18,6 @@ composer.phar
|
|||||||
wp_*.sh
|
wp_*.sh
|
||||||
auth.json
|
auth.json
|
||||||
dfm.sh
|
dfm.sh
|
||||||
|
.scannerwork
|
||||||
|
.phpactor.json
|
||||||
|
.zsh_history
|
||||||
|
|||||||
2
config/git/overrides/.gitignore
vendored
Normal file
2
config/git/overrides/.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
!.gitkeep
|
||||||
|
config
|
||||||
@@ -17,11 +17,12 @@
|
|||||||
llog = log --pretty=fuller
|
llog = log --pretty=fuller
|
||||||
logs = log --graph --pretty=format:'%C(magenta)%h%Creset -%C(red)%d%Creset %s %C(dim green)(%cr) %C(cyan)<%an>%Creset' --abbrev-commit
|
logs = log --graph --pretty=format:'%C(magenta)%h%Creset -%C(red)%d%Creset %s %C(dim green)(%cr) %C(cyan)<%an>%Creset' --abbrev-commit
|
||||||
nah = !git reset --hard && git clean -df
|
nah = !git reset --hard && git clean -df
|
||||||
|
recent = "!r() { count=$1; git for-each-ref --sort=-committerdate refs/heads --format='%(HEAD)%(color:yellow)%(refname:short)|%(color:bold green)%(committerdate:relative)|%(color:blue)%(subject)|%(color:magenta)%(authorname)%(color:reset)' --color=always --count=${count:=10} | column -ts'|';}; r"
|
||||||
reset-origin = !git fetch origin && git reset --hard origin/master && git clean -f -d
|
reset-origin = !git fetch origin && git reset --hard origin/master && git clean -f -d
|
||||||
reset-upstream = !git fetch upstream && git reset --hard upstream/master && git clean -f -d
|
reset-upstream = !git fetch upstream && git reset --hard upstream/master && git clean -f -d
|
||||||
recent = "!r() { count=$1; git for-each-ref --sort=-committerdate refs/heads --format='%(HEAD)%(color:yellow)%(refname:short)|%(color:bold green)%(committerdate:relative)|%(color:blue)%(subject)|%(color:magenta)%(authorname)%(color:reset)' --color=always --count=${count:=10} | column -ts'|';}; r"
|
|
||||||
rl = reflog --format='%C(auto)%h %<|(20)%gd %C(blue)%cr%C(reset) %gs (%s)'
|
rl = reflog --format='%C(auto)%h %<|(20)%gd %C(blue)%cr%C(reset) %gs (%s)'
|
||||||
tagdate = log --date-order --graph --tags --simplify-by-decoration --pretty=format:\"%ai %h %d\"
|
tagdate = log --date-order --graph --tags --simplify-by-decoration --pretty=format:\"%ai %h %d\"
|
||||||
|
undo = reset --soft HEAD^
|
||||||
undo-commit = reset HEAD~ --soft
|
undo-commit = reset HEAD~ --soft
|
||||||
|
|
||||||
[filter "lfs"]
|
[filter "lfs"]
|
||||||
@@ -30,15 +31,6 @@
|
|||||||
process = git-lfs filter-process
|
process = git-lfs filter-process
|
||||||
required = true
|
required = true
|
||||||
|
|
||||||
[diff]
|
|
||||||
tool = difftastic
|
|
||||||
|
|
||||||
[difftool]
|
|
||||||
prompt = false
|
|
||||||
|
|
||||||
[difftool "difftastic"]
|
|
||||||
cmd = difft "$LOCAL" "$REMOTE"
|
|
||||||
|
|
||||||
[color]
|
[color]
|
||||||
ui = true
|
ui = true
|
||||||
diff = auto
|
diff = auto
|
||||||
|
|||||||
6
config/glow/glow.yml
Normal file
6
config/glow/glow.yml
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
# mouse support (TUI-mode only)
|
||||||
|
mouse: false
|
||||||
|
# use pager to display markdown
|
||||||
|
pager: true
|
||||||
|
# word-wrap at width
|
||||||
|
width: 80
|
||||||
2
config/gnupg/dirmngr.conf
Normal file
2
config/gnupg/dirmngr.conf
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
disable-ipv6
|
||||||
|
enable-ssh-support
|
||||||
2
config/gnupg/gpg-agent.conf
Normal file
2
config/gnupg/gpg-agent.conf
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
disable-ipv6
|
||||||
|
enable-ssh-support
|
||||||
@@ -1,27 +1,38 @@
|
|||||||
tap "1password/tap"
|
tap "1password/tap"
|
||||||
tap "anchore/grype"
|
tap "anchore/grype"
|
||||||
|
tap "cormacrelf/tap"
|
||||||
tap "ddosify/tap"
|
tap "ddosify/tap"
|
||||||
tap "dm3ch/tap"
|
tap "dm3ch/tap"
|
||||||
|
tap "doron-cohen/tap"
|
||||||
tap "gesquive/tap"
|
tap "gesquive/tap"
|
||||||
tap "github/gh"
|
tap "github/gh"
|
||||||
tap "homebrew/autoupdate"
|
tap "homebrew/autoupdate"
|
||||||
tap "homebrew/bundle"
|
tap "homebrew/bundle"
|
||||||
tap "homebrew/cask-fonts"
|
|
||||||
tap "homebrew/services"
|
tap "homebrew/services"
|
||||||
tap "jesseduffield/lazygit"
|
tap "jesseduffield/lazygit"
|
||||||
|
tap "k8sgpt-ai/k8sgpt"
|
||||||
|
tap "keith/formulae"
|
||||||
tap "mongodb/brew"
|
tap "mongodb/brew"
|
||||||
|
tap "nikitabobko/tap"
|
||||||
|
tap "pantheon-systems/external"
|
||||||
|
tap "reviewdog/tap"
|
||||||
tap "shivammathur/extensions"
|
tap "shivammathur/extensions"
|
||||||
tap "shivammathur/php"
|
tap "shivammathur/php"
|
||||||
|
tap "snyk/tap"
|
||||||
tap "teamookla/speedtest"
|
tap "teamookla/speedtest"
|
||||||
tap "xwmx/taps"
|
tap "xwmx/taps"
|
||||||
# Run your GitHub Actions locally
|
# Run your GitHub Actions locally
|
||||||
brew "act"
|
brew "act"
|
||||||
|
# Simple, modern, secure file encryption
|
||||||
|
brew "age"
|
||||||
# Mozilla CA certificate store
|
# Mozilla CA certificate store
|
||||||
brew "ca-certificates"
|
brew "ca-certificates"
|
||||||
|
# Mozilla CA bundle for Python
|
||||||
|
brew "certifi"
|
||||||
# Cryptography and SSL/TLS Toolkit
|
# Cryptography and SSL/TLS Toolkit
|
||||||
brew "openssl@3"
|
brew "openssl@3"
|
||||||
# Interpreted, interactive, object-oriented programming language
|
# Cryptographic recipes and primitives for Python
|
||||||
brew "python@3.11"
|
brew "cryptography"
|
||||||
# YAML Parser
|
# YAML Parser
|
||||||
brew "libyaml"
|
brew "libyaml"
|
||||||
# Automate deployment, configuration, and upgrading
|
# Automate deployment, configuration, and upgrading
|
||||||
@@ -50,28 +61,32 @@ brew "apr"
|
|||||||
brew "apr-util"
|
brew "apr-util"
|
||||||
# Password hashing library and CLI utility
|
# Password hashing library and CLI utility
|
||||||
brew "argon2"
|
brew "argon2"
|
||||||
# Open Source Kubernetes Marketplace
|
|
||||||
brew "arkade"
|
|
||||||
# Automatic configure script builder
|
|
||||||
brew "autoconf"
|
|
||||||
# GNU multiple precision arithmetic library
|
|
||||||
brew "gmp"
|
|
||||||
# GNU File, Shell, and Text utilities
|
|
||||||
brew "coreutils"
|
|
||||||
# Extendable version manager with support for Ruby, Node.js, Erlang & more
|
|
||||||
brew "asdf"
|
|
||||||
# Spell checker with better logic than ispell
|
# Spell checker with better logic than ispell
|
||||||
brew "aspell"
|
brew "aspell"
|
||||||
|
# Automatic configure script builder
|
||||||
|
brew "autoconf"
|
||||||
|
# Collection of over 500 reusable autoconf macros
|
||||||
|
brew "autoconf-archive"
|
||||||
|
# GNU multiple precision arithmetic library
|
||||||
|
brew "gmp"
|
||||||
|
# Package compiler and linker metadata toolkit
|
||||||
|
brew "pkgconf"
|
||||||
|
# Automated text file generator
|
||||||
|
brew "autogen"
|
||||||
|
# Tool for generating GNU Standards-compliant Makefiles
|
||||||
|
brew "automake"
|
||||||
# Official Amazon AWS command-line interface
|
# Official Amazon AWS command-line interface
|
||||||
brew "awscli"
|
brew "awscli"
|
||||||
# Bourne-Again SHell, a UNIX command interpreter
|
# Bourne-Again SHell, a UNIX command interpreter
|
||||||
brew "bash"
|
brew "bash"
|
||||||
# Clone of cat(1) with syntax highlighting and Git integration
|
# Clone of cat(1) with syntax highlighting and Git integration
|
||||||
brew "bat"
|
brew "bat"
|
||||||
# Yet another cross-platform graphical process/system monitor
|
# GNU File, Shell, and Text utilities
|
||||||
brew "bottom"
|
brew "coreutils"
|
||||||
# Switch Apache / Valet / CLI configs between PHP versions
|
# Bash Automated Testing System
|
||||||
brew "brew-php-switcher"
|
brew "bats-core"
|
||||||
|
# Parser generator
|
||||||
|
brew "bison"
|
||||||
# Software library to render fonts
|
# Software library to render fonts
|
||||||
brew "freetype"
|
brew "freetype"
|
||||||
# XML-based font configuration API for X Windows
|
# XML-based font configuration API for X Windows
|
||||||
@@ -80,38 +95,24 @@ brew "fontconfig"
|
|||||||
brew "gettext"
|
brew "gettext"
|
||||||
# Core application library for C
|
# Core application library for C
|
||||||
brew "glib"
|
brew "glib"
|
||||||
# Manage compile and link flags for libraries
|
# Prevent cloud misconfigurations during build-time for IaC tools
|
||||||
brew "pkg-config"
|
brew "checkov"
|
||||||
# Human-friendly and fast alternative to cut and (sometimes) awk
|
# Human-friendly and fast alternative to cut and (sometimes) awk
|
||||||
brew "choose-rust"
|
brew "choose-rust"
|
||||||
# Cross-platform make
|
# Cross-platform make
|
||||||
brew "cmake"
|
brew "cmake"
|
||||||
# Get, unpack, build, and install modules from CPAN
|
|
||||||
brew "cpanminus"
|
|
||||||
# Open source suite of directory software
|
|
||||||
brew "openldap"
|
|
||||||
# Get a file from an HTTP, HTTPS or FTP server
|
# Get a file from an HTTP, HTTPS or FTP server
|
||||||
brew "curl"
|
brew "curl"
|
||||||
# Diff that understands syntax
|
|
||||||
brew "difftastic"
|
|
||||||
# Tool for exploring each layer in a docker image
|
|
||||||
brew "dive"
|
|
||||||
# Lightweight DNS forwarder and DHCP server
|
# Lightweight DNS forwarder and DHCP server
|
||||||
brew "dnsmasq"
|
brew "dnsmasq"
|
||||||
# Command-line DNS client
|
# Spellchecker wrapping library
|
||||||
brew "dog"
|
brew "enchant"
|
||||||
# Lightning-fast linter for .env files written in Rust
|
|
||||||
brew "dotenv-linter"
|
|
||||||
# Useful examples at the command-line
|
|
||||||
brew "eg-examples"
|
|
||||||
# Run arbitrary commands when files change
|
|
||||||
brew "entr"
|
|
||||||
# Perl lib for reading and writing EXIF metadata
|
# Perl lib for reading and writing EXIF metadata
|
||||||
brew "exiftool"
|
brew "exiftool"
|
||||||
# Simple, fast and user-friendly alternative to find
|
|
||||||
brew "fd"
|
|
||||||
# Banner-like program prints strings as ASCII art
|
# Banner-like program prints strings as ASCII art
|
||||||
brew "figlet"
|
brew "figlet"
|
||||||
|
# Lock file during command
|
||||||
|
brew "flock"
|
||||||
# Libraries to talk to Microsoft SQL Server and Sybase databases
|
# Libraries to talk to Microsoft SQL Server and Sybase databases
|
||||||
brew "freetds"
|
brew "freetds"
|
||||||
# Monitor a directory for changes and run a shell command
|
# Monitor a directory for changes and run a shell command
|
||||||
@@ -121,9 +122,15 @@ brew "fzf"
|
|||||||
# Graphics library to dynamically manipulate images
|
# Graphics library to dynamically manipulate images
|
||||||
brew "gd"
|
brew "gd"
|
||||||
# Disk usage analyzer with console interface written in Go
|
# Disk usage analyzer with console interface written in Go
|
||||||
brew "gdu", link: false
|
brew "gdu"
|
||||||
# GitHub command-line tool
|
# GitHub command-line tool
|
||||||
brew "gh"
|
brew "gh"
|
||||||
|
# OpenType text shaping engine
|
||||||
|
brew "harfbuzz"
|
||||||
|
# Secure hashing function
|
||||||
|
brew "libb2"
|
||||||
|
# Framework for layout and rendering of i18n text
|
||||||
|
brew "pango"
|
||||||
# Distributed revision control system
|
# Distributed revision control system
|
||||||
brew "git"
|
brew "git"
|
||||||
# Enable transparent encryption/decryption of files in a git repo
|
# Enable transparent encryption/decryption of files in a git repo
|
||||||
@@ -132,8 +139,6 @@ brew "git-crypt"
|
|||||||
brew "git-extras"
|
brew "git-extras"
|
||||||
# See your latest local git branches, formatted real fancy
|
# See your latest local git branches, formatted real fancy
|
||||||
brew "git-recent"
|
brew "git-recent"
|
||||||
# Open-source GitLab command-line tool
|
|
||||||
brew "glab"
|
|
||||||
# Render markdown on the CLI
|
# Render markdown on the CLI
|
||||||
brew "glow"
|
brew "glow"
|
||||||
# GNU implementation of the famous stream editor
|
# GNU implementation of the famous stream editor
|
||||||
@@ -144,20 +149,12 @@ brew "unbound"
|
|||||||
brew "gnutls"
|
brew "gnutls"
|
||||||
# GNU Pretty Good Privacy (PGP) package
|
# GNU Pretty Good Privacy (PGP) package
|
||||||
brew "gnupg"
|
brew "gnupg"
|
||||||
# Open source programming language to build simple/reliable/efficient software
|
|
||||||
brew "go"
|
|
||||||
# Library access to GnuPG
|
# Library access to GnuPG
|
||||||
brew "gpgme"
|
brew "gpgme"
|
||||||
# Manage your GnuPG keys with ease!
|
# Manage your GnuPG keys with ease!
|
||||||
brew "gpg-tui"
|
brew "gpg-tui"
|
||||||
# Image manipulation
|
# Image manipulation
|
||||||
brew "netpbm"
|
brew "netpbm"
|
||||||
# C/C++ and Java libraries for Unicode and globalization
|
|
||||||
brew "icu4c"
|
|
||||||
# OpenType text shaping engine
|
|
||||||
brew "harfbuzz"
|
|
||||||
# Framework for layout and rendering of i18n text
|
|
||||||
brew "pango"
|
|
||||||
# Library to render SVG files using Cairo
|
# Library to render SVG files using Cairo
|
||||||
brew "librsvg"
|
brew "librsvg"
|
||||||
# Graph visualization software from AT&T and Bell Labs
|
# Graph visualization software from AT&T and Bell Labs
|
||||||
@@ -166,60 +163,68 @@ brew "graphviz"
|
|||||||
brew "grep"
|
brew "grep"
|
||||||
# Popular GNU data compression program
|
# Popular GNU data compression program
|
||||||
brew "gzip"
|
brew "gzip"
|
||||||
# Smarter Dockerfile linter to validate best practices
|
# Text-based UI library
|
||||||
brew "hadolint"
|
brew "ncurses"
|
||||||
# Improved top (interactive process viewer)
|
# Improved top (interactive process viewer)
|
||||||
brew "htop"
|
brew "htop"
|
||||||
# Website copier/offline browser
|
# Portable abstraction of the hierarchical topology of modern architectures
|
||||||
brew "httrack"
|
brew "hwloc"
|
||||||
# Configurable static site generator
|
|
||||||
brew "hugo"
|
|
||||||
# ISO/IEC 23008-12:2017 HEIF file format decoder and encoder
|
# ISO/IEC 23008-12:2017 HEIF file format decoder and encoder
|
||||||
brew "libheif"
|
brew "libheif"
|
||||||
# Tools and libraries to manipulate images in many formats
|
# Tools and libraries to manipulate images in many formats
|
||||||
brew "imagemagick"
|
brew "imagemagick"
|
||||||
|
# Modular IRC client
|
||||||
|
brew "irssi"
|
||||||
|
# Image manipulation library
|
||||||
|
brew "jpeg"
|
||||||
# Lightweight and flexible command-line JSON processor
|
# Lightweight and flexible command-line JSON processor
|
||||||
brew "jq"
|
brew "jq"
|
||||||
|
# JSON parser for C
|
||||||
|
brew "json-c"
|
||||||
# Network authentication protocol
|
# Network authentication protocol
|
||||||
brew "krb5"
|
brew "krb5"
|
||||||
# Lazier way to manage everything docker
|
# Tool to detect/remediate misconfig and security risks of GitHub/GitLab assets
|
||||||
brew "lazydocker"
|
brew "legitify"
|
||||||
|
# BSD-style licensed readline alternative
|
||||||
|
brew "libedit"
|
||||||
|
# Conversion library
|
||||||
|
brew "libiconv"
|
||||||
# Postgres C API library
|
# Postgres C API library
|
||||||
brew "libpq"
|
brew "libpq"
|
||||||
# Linguistic software and Finnish dictionary
|
# Version of the SSL/TLS protocol forked from OpenSSL
|
||||||
brew "libvoikko"
|
brew "libressl"
|
||||||
# Rainbows and unicorns in your console!
|
# Multi-platform support library with a focus on asynchronous I/O
|
||||||
brew "lolcat"
|
brew "libuv"
|
||||||
|
# GNOME XML library
|
||||||
|
brew "libxml2"
|
||||||
# Package manager for the Lua programming language
|
# Package manager for the Lua programming language
|
||||||
brew "luarocks"
|
brew "luarocks"
|
||||||
|
# LZMA-based compression program similar to gzip or bzip2
|
||||||
|
brew "lzip"
|
||||||
# Swiss Army Knife for macOS
|
# Swiss Army Knife for macOS
|
||||||
brew "m-cli"
|
brew "m-cli"
|
||||||
# Mac App Store command-line interface
|
# Collection of tools that nobody wrote when UNIX was young
|
||||||
brew "mas"
|
brew "moreutils"
|
||||||
# NCurses Disk Usage
|
# NCurses Disk Usage
|
||||||
brew "ncdu"
|
brew "ncdu"
|
||||||
# Ambitious Vim-fork focused on extensibility and agility
|
|
||||||
brew "neovim"
|
|
||||||
# HTTP(S) server and reverse proxy, and IMAP/POP3 proxy server
|
# HTTP(S) server and reverse proxy, and IMAP/POP3 proxy server
|
||||||
brew "nginx"
|
brew "nginx"
|
||||||
# Port scanning utility for large networks
|
# Port scanning utility for large networks
|
||||||
brew "nmap"
|
brew "nmap"
|
||||||
# Manage multiple Node.js versions
|
# Libraries for security-enabled client and server applications
|
||||||
brew "nvm"
|
brew "nss"
|
||||||
# Development kit for the Java programming language
|
# Open source suite of directory software
|
||||||
brew "openjdk@11"
|
brew "openldap"
|
||||||
# Generate clients, server & docs from an OpenAPI spec (v2, v3)
|
# Cryptography and SSL/TLS Toolkit
|
||||||
brew "openapi-generator"
|
brew "openssl@1.1"
|
||||||
# Development kit for the Java programming language
|
# ISO-C API and CLI for generating UUIDs
|
||||||
brew "openjdk"
|
brew "ossp-uuid"
|
||||||
# Swiss-army knife of markup format conversion
|
|
||||||
brew "pandoc"
|
|
||||||
# Highly capable, feature-rich programming language
|
|
||||||
brew "perl"
|
|
||||||
# General-purpose scripting language
|
# General-purpose scripting language
|
||||||
brew "php@8.1"
|
brew "php"
|
||||||
# Simple Python style checker in one Python file
|
# General-purpose scripting language
|
||||||
brew "pycodestyle"
|
brew "php@8.2"
|
||||||
|
# General-purpose scripting language
|
||||||
|
brew "php@8.3"
|
||||||
# Python version management
|
# Python version management
|
||||||
brew "pyenv"
|
brew "pyenv"
|
||||||
# Migrate pip packages from one Python version to another
|
# Migrate pip packages from one Python version to another
|
||||||
@@ -227,51 +232,29 @@ brew "pyenv-pip-migrate"
|
|||||||
# Pyenv plugin to manage virtualenv
|
# Pyenv plugin to manage virtualenv
|
||||||
brew "pyenv-virtualenv"
|
brew "pyenv-virtualenv"
|
||||||
# Interpreted, interactive, object-oriented programming language
|
# Interpreted, interactive, object-oriented programming language
|
||||||
brew "python@3.10"
|
brew "python@3.11"
|
||||||
# Interpreted, interactive, object-oriented programming language
|
# Install various Ruby versions and implementations
|
||||||
brew "python@3.8"
|
brew "ruby-build"
|
||||||
# Ruby version manager
|
# Ruby version manager
|
||||||
brew "rbenv"
|
brew "rbenv"
|
||||||
# RC file (dotfile) management
|
# Generate C-based recognizers from regular expressions
|
||||||
brew "rcm"
|
brew "re2c"
|
||||||
# Search tool like grep and The Silver Searcher
|
|
||||||
brew "ripgrep"
|
|
||||||
# Safe, concurrent, practical language
|
|
||||||
brew "rust"
|
|
||||||
# Static analysis and lint tool, for (ba)sh scripts
|
# Static analysis and lint tool, for (ba)sh scripts
|
||||||
brew "shellcheck"
|
brew "shellcheck"
|
||||||
# Autoformat shell script source code
|
|
||||||
brew "shfmt"
|
|
||||||
# Support CI generation of SBOMs via golang tooling
|
|
||||||
brew "spdx-sbom-generator"
|
|
||||||
# Version control system designed to be a better CVS
|
|
||||||
brew "subversion"
|
|
||||||
# Feature-rich console based todo list manager
|
|
||||||
brew "task"
|
|
||||||
# Terminal user interface for taskwarrior
|
|
||||||
brew "taskwarrior-tui"
|
|
||||||
# Very fast implementation of tldr in Rust
|
|
||||||
brew "tealdeer"
|
|
||||||
# Send macOS User Notifications from the command-line
|
# Send macOS User Notifications from the command-line
|
||||||
brew "terminal-notifier"
|
brew "terminal-notifier"
|
||||||
# Thin wrapper for Terraform e.g. for locking state
|
|
||||||
brew "terragrunt"
|
|
||||||
# Tool which checks for the support of TLS/SSL ciphers and flaws
|
# Tool which checks for the support of TLS/SSL ciphers and flaws
|
||||||
brew "testssl"
|
brew "testssl"
|
||||||
# Terraform version manager inspired by rbenv
|
# Terraform version manager inspired by rbenv
|
||||||
brew "tfenv"
|
brew "tfenv"
|
||||||
|
# Linter for Terraform files
|
||||||
|
brew "tflint"
|
||||||
# Static analysis security scanner for your terraform code
|
# Static analysis security scanner for your terraform code
|
||||||
brew "tfsec"
|
brew "tfsec"
|
||||||
# Programmatically correct mistyped console commands
|
|
||||||
brew "thefuck"
|
|
||||||
# Terminal multiplexer
|
# Terminal multiplexer
|
||||||
brew "tmux"
|
brew "tmux"
|
||||||
# Display directories as trees (with optional color/HTML output)
|
# Display directories as trees (with optional color/HTML output)
|
||||||
brew "tree"
|
brew "tree"
|
||||||
# Vulnerability scanner for container images, file systems, and Git repos
|
|
||||||
brew "trivy"
|
|
||||||
# Modern watch command
|
|
||||||
brew "viddy"
|
|
||||||
# Tool for creating isolated virtual python environments
|
# Tool for creating isolated virtual python environments
|
||||||
brew "virtualenv"
|
brew "virtualenv"
|
||||||
# Command-line interface to the WakaTime api
|
# Command-line interface to the WakaTime api
|
||||||
@@ -280,114 +263,91 @@ brew "wakatime-cli"
|
|||||||
brew "watch"
|
brew "watch"
|
||||||
# Internet file retriever
|
# Internet file retriever
|
||||||
brew "wget"
|
brew "wget"
|
||||||
# Personal information dashboard for your terminal
|
|
||||||
brew "wtfutil"
|
|
||||||
# Check your $HOME for unwanted files and directories
|
# Check your $HOME for unwanted files and directories
|
||||||
brew "xdg-ninja", args: ["HEAD"]
|
brew "xdg-ninja", args: ["HEAD"]
|
||||||
# Hackable, minimal, fast TUI file explorer
|
# General-purpose lossless data-compression library
|
||||||
brew "xplr"
|
brew "zlib"
|
||||||
# JavaScript package manager
|
# Watcher for macOS 10.14+ light/dark mode changes
|
||||||
brew "yarn"
|
brew "cormacrelf/tap/dark-notify"
|
||||||
# A vulnerability scanner for container images and filesystems
|
# Cleans up your $HOME from those pesky dotfiles
|
||||||
brew "anchore/grype/grype"
|
brew "doron-cohen/tap/antidot"
|
||||||
# High-performance load testing tool, written in Golang.
|
|
||||||
brew "ddosify/tap/ddosify"
|
|
||||||
# lets you quickly switch between multiple git user profiles
|
# lets you quickly switch between multiple git user profiles
|
||||||
brew "gesquive/tap/git-user"
|
brew "gesquive/tap/git-user"
|
||||||
# A simple terminal UI for git commands, written in Go
|
# Terminus is Pantheon's Command-line Interface (CLI)
|
||||||
brew "jesseduffield/lazygit/lazygit"
|
brew "pantheon-systems/external/terminus"
|
||||||
# High-performance, schema-free, document-oriented database
|
# Automated code review tool integrated with any code analysis tools regardless of programming language.
|
||||||
brew "mongodb/brew/mongodb-community"
|
brew "reviewdog/tap/reviewdog"
|
||||||
|
# Igbinary PHP extension
|
||||||
|
brew "shivammathur/extensions/igbinary@8.3"
|
||||||
# Imagick PHP extension
|
# Imagick PHP extension
|
||||||
brew "shivammathur/extensions/imagick@8.2"
|
brew "shivammathur/extensions/imagick@8.3"
|
||||||
# Xdebug PHP extension
|
# Mcrypt PHP extension
|
||||||
brew "shivammathur/extensions/xdebug@7.4"
|
brew "shivammathur/extensions/mcrypt@8.3"
|
||||||
# Xdebug PHP extension
|
# Msgpack PHP extension
|
||||||
brew "shivammathur/extensions/xdebug@8.0"
|
brew "shivammathur/extensions/msgpack@8.3"
|
||||||
# Xdebug PHP extension
|
# PCOV PHP extension
|
||||||
brew "shivammathur/extensions/xdebug@8.1"
|
brew "shivammathur/extensions/pcov@8.3"
|
||||||
|
# Redis PHP extension
|
||||||
|
brew "shivammathur/extensions/redis@8.3"
|
||||||
|
# Uuid PHP extension
|
||||||
|
brew "shivammathur/extensions/uuid@8.3"
|
||||||
|
# Yaml PHP extension
|
||||||
|
brew "shivammathur/extensions/yaml@8.3"
|
||||||
# General-purpose scripting language
|
# General-purpose scripting language
|
||||||
brew "shivammathur/php/php"
|
brew "shivammathur/php/php-debug"
|
||||||
# General-purpose scripting language
|
# General-purpose scripting language
|
||||||
brew "shivammathur/php/php@7.4"
|
brew "shivammathur/php/php@7.4"
|
||||||
# General-purpose scripting language
|
# General-purpose scripting language
|
||||||
brew "shivammathur/php/php@8.0"
|
brew "shivammathur/php/php@8.0", link: true
|
||||||
# Ookla Speedtest
|
# Find & fix known vulnerabilities in open-source dependencies
|
||||||
brew "teamookla/speedtest/speedtest"
|
brew "snyk/tap/snyk"
|
||||||
# Command-line helper for the 1Password password manager
|
# AeroSpace is an i3-like tiling window manager for macOS
|
||||||
cask "1password-cli"
|
cask "aerospace"
|
||||||
# Turn audio CDs and files into audiobooks
|
|
||||||
cask "audiobook-builder"
|
|
||||||
# Text editor
|
# Text editor
|
||||||
cask "coda"
|
cask "coda"
|
||||||
# Universal database tool and SQL client
|
# Universal database tool and SQL client
|
||||||
cask "dbeaver-community"
|
cask "dbeaver-community"
|
||||||
# Database version management tool
|
# Database version management tool
|
||||||
cask "dbngin"
|
cask "dbngin"
|
||||||
# App to build and share containerized applications and microservices
|
# App to build and share containerised applications and microservices
|
||||||
cask "docker"
|
cask "docker"
|
||||||
# UI toolkit for building applications for mobile, web and desktop
|
|
||||||
cask "flutter"
|
|
||||||
# Unofficial overcast.fm podcast app
|
|
||||||
cask "fog"
|
|
||||||
# Typeface made for developers
|
|
||||||
cask "font-jetbrains-mono"
|
cask "font-jetbrains-mono"
|
||||||
# Developer targeted fonts with a high number of glyphs
|
|
||||||
cask "font-jetbrains-mono-nerd-font"
|
cask "font-jetbrains-mono-nerd-font"
|
||||||
cask "font-lato"
|
|
||||||
cask "font-open-sans"
|
cask "font-open-sans"
|
||||||
# Font with a mechanical skeleton and the forms are largely geometric
|
|
||||||
cask "font-roboto"
|
|
||||||
cask "font-source-code-pro"
|
|
||||||
cask "font-source-code-pro-for-powerline"
|
|
||||||
cask "font-source-sans-pro"
|
|
||||||
cask "font-source-serif-pro"
|
|
||||||
# Open Source Webfont Converter
|
|
||||||
cask "fontplop"
|
|
||||||
# GIT client
|
# GIT client
|
||||||
cask "fork"
|
cask "fork"
|
||||||
# Set of tools to manage resources and applications hosted on Google Cloud
|
|
||||||
cask "google-cloud-sdk"
|
|
||||||
# HTTP and GraphQL Client
|
# HTTP and GraphQL Client
|
||||||
cask "insomnia"
|
cask "insomnia"
|
||||||
# JetBrains tools manager
|
# JetBrains tools manager
|
||||||
cask "jetbrains-toolbox"
|
cask "jetbrains-toolbox"
|
||||||
|
# End-to-end encryption software
|
||||||
|
cask "keybase"
|
||||||
# Kubernetes IDE
|
# Kubernetes IDE
|
||||||
cask "lens"
|
cask "lens"
|
||||||
# Keep all tasks from your todo apps on your menu bar
|
|
||||||
cask "monofocus"
|
|
||||||
# Reverse proxy, secure introspectable tunnels to localhost
|
# Reverse proxy, secure introspectable tunnels to localhost
|
||||||
cask "ngrok"
|
cask "ngrok"
|
||||||
# Simple application that will prevent iTunes or Apple Music from launching
|
# Simple application that will prevent iTunes or Apple Music from launching
|
||||||
cask "notunes"
|
cask "notunes"
|
||||||
# Knowledge base that works on top of a local folder of plain text Markdown files
|
# Knowledge base that works on top of a local folder of plain text Markdown files
|
||||||
cask "obsidian"
|
cask "obsidian"
|
||||||
# Scheduling application focusing on organization
|
|
||||||
cask "omnifocus"
|
|
||||||
# Collaboration platform for API development
|
|
||||||
cask "postman"
|
|
||||||
# Display image info and preview unsupported formats in QuickLook
|
# Display image info and preview unsupported formats in QuickLook
|
||||||
cask "qlimagesize"
|
cask "qlimagesize"
|
||||||
# QuickLook generator for Markdown files
|
# Quick Look generator for Markdown files
|
||||||
cask "qlmarkdown"
|
cask "qlmarkdown"
|
||||||
# QuickLook plugin for plaintext files without an extension
|
# Quick Look plugin for plaintext files without an extension
|
||||||
cask "qlstephen"
|
cask "qlstephen"
|
||||||
# QuickLook plugin for JSON files
|
# Quick Look plugin for JSON files
|
||||||
cask "quicklook-json"
|
cask "quicklook-json"
|
||||||
# QuickLook generator for Adobe Swatch Exchange files
|
# Quick Look generator for Adobe Swatch Exchange files
|
||||||
cask "quicklookase"
|
cask "quicklookase"
|
||||||
# Automatically hides or quits apps after periods of inactivity
|
# Automatically hides or quits apps after periods of inactivity
|
||||||
cask "quitter"
|
cask "quitter"
|
||||||
# Control your tools with a few keystrokes
|
# Control your tools with a few keystrokes
|
||||||
cask "raycast"
|
cask "raycast"
|
||||||
# Move and resize windows using keyboard shortcuts or snap areas
|
|
||||||
cask "rectangle"
|
|
||||||
# GUI for rsync
|
|
||||||
cask "rsyncosx"
|
|
||||||
# GUI for rsync
|
|
||||||
cask "rsyncui"
|
|
||||||
# MySQL/MariaDB database management
|
# MySQL/MariaDB database management
|
||||||
cask "sequel-ace"
|
cask "sequel-ace"
|
||||||
|
# Plugin for AWS CLI to start and end sessions that connect to managed instances
|
||||||
|
cask "session-manager-plugin"
|
||||||
# Collection of apps available by subscription
|
# Collection of apps available by subscription
|
||||||
cask "setapp"
|
cask "setapp"
|
||||||
# Team communication and collaboration software
|
# Team communication and collaboration software
|
||||||
@@ -398,91 +358,21 @@ cask "soundsource"
|
|||||||
cask "suspicious-package"
|
cask "suspicious-package"
|
||||||
# Quicklook extension for source files
|
# Quicklook extension for source files
|
||||||
cask "syntax-highlight"
|
cask "syntax-highlight"
|
||||||
|
# Python IDE for beginners
|
||||||
|
cask "thonny"
|
||||||
|
# To-do list
|
||||||
|
cask "todoist"
|
||||||
|
# Configuration application for the Ultimate Hacking Keyboard
|
||||||
|
cask "uhk-agent"
|
||||||
# Open-source code editor
|
# Open-source code editor
|
||||||
cask "visual-studio-code"
|
cask "visual-studio-code"
|
||||||
# Multimedia player
|
# Multimedia player
|
||||||
cask "vlc"
|
cask "vlc"
|
||||||
# Spell-checking service for Finnish
|
# Spell-checking service for Finnish
|
||||||
cask "voikkospellservice"
|
cask "voikkospellservice"
|
||||||
# Rust-based terminal
|
# GPU-accelerated cross-platform terminal emulator and multiplexer
|
||||||
cask "warp"
|
cask "wezterm"
|
||||||
mas "1Password for Safari", id: 1569813296
|
# Application for generating TOTP and HOTP codes
|
||||||
mas "Actions", id: 1586435171
|
cask "yubico-authenticator"
|
||||||
mas "Audiobook Builder", id: 1437681957
|
# Multiplayer code editor
|
||||||
mas "Ivory", id: 6444602274
|
cask "zed"
|
||||||
mas "Keynote", id: 409183694
|
|
||||||
mas "LastPass", id: 926036361
|
|
||||||
mas "Numbers", id: 409203825
|
|
||||||
mas "Pages", id: 409201541
|
|
||||||
mas "Tailscale", id: 1475387142
|
|
||||||
mas "Xcode", id: 497799835
|
|
||||||
vscode "akamud.vscode-theme-onelight"
|
|
||||||
vscode "amiralizadeh9480.laravel-extra-intellisense"
|
|
||||||
vscode "andrewleedham.vscode-css-modules"
|
|
||||||
vscode "andrewmcodes.tailwindcss-extension-pack"
|
|
||||||
vscode "austenc.tailwind-docs"
|
|
||||||
vscode "bmewburn.vscode-intelephense-client"
|
|
||||||
vscode "Box-Of-Hats.bemhelper"
|
|
||||||
vscode "bradlc.vscode-tailwindcss"
|
|
||||||
vscode "christian-kohler.npm-intellisense"
|
|
||||||
vscode "christian-kohler.path-intellisense"
|
|
||||||
vscode "DavidAnson.vscode-markdownlint"
|
|
||||||
vscode "dbaeumer.vscode-eslint"
|
|
||||||
vscode "DotJoshJohnson.xml"
|
|
||||||
vscode "eamodio.gitlens"
|
|
||||||
vscode "EditorConfig.EditorConfig"
|
|
||||||
vscode "esbenp.prettier-vscode"
|
|
||||||
vscode "formulahendry.auto-close-tag"
|
|
||||||
vscode "formulahendry.auto-rename-tag"
|
|
||||||
vscode "formulahendry.code-runner"
|
|
||||||
vscode "gencer.html-slim-scss-css-class-completion"
|
|
||||||
vscode "github.vscode-github-actions"
|
|
||||||
vscode "GitHub.vscode-pull-request-github"
|
|
||||||
vscode "GraphQL.vscode-graphql"
|
|
||||||
vscode "GraphQL.vscode-graphql-execution"
|
|
||||||
vscode "GraphQL.vscode-graphql-syntax"
|
|
||||||
vscode "heybourn.headwind"
|
|
||||||
vscode "JohnnyMorganz.stylua"
|
|
||||||
vscode "jumpinjackie.vscode-map-preview"
|
|
||||||
vscode "k--kato.intellij-idea-keybindings"
|
|
||||||
vscode "liamhammett.inline-parameters"
|
|
||||||
vscode "macieklad.tailwind-sass-syntax"
|
|
||||||
vscode "MehediDracula.php-namespace-resolver"
|
|
||||||
vscode "mikestead.dotenv"
|
|
||||||
vscode "MisterJ.vue-volar-extention-pack"
|
|
||||||
vscode "MrChetan.phpstorm-parameter-hints-in-vscode"
|
|
||||||
vscode "mrorz.language-gettext"
|
|
||||||
vscode "ms-azuretools.vscode-docker"
|
|
||||||
vscode "ms-python.python"
|
|
||||||
vscode "ms-python.vscode-pylance"
|
|
||||||
vscode "ms-toolsai.jupyter"
|
|
||||||
vscode "ms-toolsai.jupyter-renderers"
|
|
||||||
vscode "ms-toolsai.vscode-jupyter-cell-tags"
|
|
||||||
vscode "ms-toolsai.vscode-jupyter-slideshow"
|
|
||||||
vscode "ms-vscode-remote.remote-containers"
|
|
||||||
vscode "ms-vscode-remote.remote-wsl"
|
|
||||||
vscode "ms-vscode.cpptools"
|
|
||||||
vscode "msjsdiag.vscode-react-native"
|
|
||||||
vscode "mtxr.sqltools"
|
|
||||||
vscode "neilbrayfield.php-docblocker"
|
|
||||||
vscode "nhoizey.gremlins"
|
|
||||||
vscode "octref.vetur"
|
|
||||||
vscode "oderwat.indent-rainbow"
|
|
||||||
vscode "pflannery.vscode-versionlens"
|
|
||||||
vscode "phiter.phpstorm-snippets"
|
|
||||||
vscode "sibiraj-s.vscode-scss-formatter"
|
|
||||||
vscode "SonarSource.sonarlint-vscode"
|
|
||||||
vscode "stylelint.vscode-stylelint"
|
|
||||||
vscode "syler.sass-indented"
|
|
||||||
vscode "timonwong.shellcheck"
|
|
||||||
vscode "tootone.org-mode"
|
|
||||||
vscode "valeryanm.vscode-phpsab"
|
|
||||||
vscode "Vue.volar"
|
|
||||||
vscode "Vue.vscode-typescript-vue-plugin"
|
|
||||||
vscode "WakaTime.vscode-wakatime"
|
|
||||||
vscode "wix.vscode-import-cost"
|
|
||||||
vscode "xdebug.php-debug"
|
|
||||||
vscode "xdebug.php-pack"
|
|
||||||
vscode "yinfei.luahelper"
|
|
||||||
vscode "yoavbls.pretty-ts-errors"
|
|
||||||
vscode "ZainChen.json"
|
|
||||||
|
|||||||
53
config/htop/htoprc
Normal file
53
config/htop/htoprc
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
# Beware! This file is rewritten by htop when settings are changed in the interface.
|
||||||
|
# The parser is also very primitive, and not human-friendly.
|
||||||
|
htop_version=3.3.0
|
||||||
|
config_reader_min_version=3
|
||||||
|
fields=0 48 17 18 38 39 2 46 47 49 1
|
||||||
|
hide_kernel_threads=1
|
||||||
|
hide_userland_threads=0
|
||||||
|
hide_running_in_container=0
|
||||||
|
shadow_other_users=0
|
||||||
|
show_thread_names=0
|
||||||
|
show_program_path=1
|
||||||
|
highlight_base_name=0
|
||||||
|
highlight_deleted_exe=1
|
||||||
|
shadow_distribution_path_prefix=0
|
||||||
|
highlight_megabytes=1
|
||||||
|
highlight_threads=1
|
||||||
|
highlight_changes=0
|
||||||
|
highlight_changes_delay_secs=5
|
||||||
|
find_comm_in_cmdline=1
|
||||||
|
strip_exe_from_cmdline=1
|
||||||
|
show_merged_command=0
|
||||||
|
header_margin=1
|
||||||
|
screen_tabs=1
|
||||||
|
detailed_cpu_time=0
|
||||||
|
cpu_count_from_one=0
|
||||||
|
show_cpu_usage=1
|
||||||
|
show_cpu_frequency=0
|
||||||
|
update_process_names=0
|
||||||
|
account_guest_in_cpu_meter=0
|
||||||
|
color_scheme=0
|
||||||
|
enable_mouse=1
|
||||||
|
delay=15
|
||||||
|
hide_function_bar=0
|
||||||
|
header_layout=two_50_50
|
||||||
|
column_meters_0=LeftCPUs2 Memory Swap
|
||||||
|
column_meter_modes_0=1 1 1
|
||||||
|
column_meters_1=RightCPUs2 Tasks LoadAverage Uptime
|
||||||
|
column_meter_modes_1=1 2 2 2
|
||||||
|
tree_view=0
|
||||||
|
sort_key=46
|
||||||
|
tree_sort_key=0
|
||||||
|
sort_direction=-1
|
||||||
|
tree_sort_direction=1
|
||||||
|
tree_view_always_by_pid=0
|
||||||
|
all_branches_collapsed=0
|
||||||
|
screen:Main=PID USER PRIORITY NICE M_VIRT M_RESIDENT STATE PERCENT_CPU PERCENT_MEM TIME Command
|
||||||
|
.sort_key=PERCENT_CPU
|
||||||
|
.tree_sort_key=PID
|
||||||
|
.tree_view_always_by_pid=0
|
||||||
|
.tree_view=0
|
||||||
|
.sort_direction=-1
|
||||||
|
.tree_sort_direction=1
|
||||||
|
.all_branches_collapsed=0
|
||||||
73
config/ideavim/ideavimrc
Normal file
73
config/ideavim/ideavimrc
Normal file
@@ -0,0 +1,73 @@
|
|||||||
|
"" Source your .vimrc
|
||||||
|
"source ~/.vimrc
|
||||||
|
|
||||||
|
"" -- Suggested options --
|
||||||
|
" Show a few lines of context around the cursor. Note that this makes the
|
||||||
|
" text scroll if you mouse-click near the start or end of the window.
|
||||||
|
set scrolloff=5
|
||||||
|
|
||||||
|
" Don't use Ex mode, use Q for formatting.
|
||||||
|
map Q gq
|
||||||
|
|
||||||
|
|
||||||
|
"" -- Map IDE actions to IdeaVim -- https://jb.gg/abva4t
|
||||||
|
"" Map \r to the Reformat Code action
|
||||||
|
"map \r <Action>(ReformatCode)
|
||||||
|
|
||||||
|
"" Map <leader>d to start debug
|
||||||
|
"map <leader>d <Action>(Debug)
|
||||||
|
|
||||||
|
"" Map \b to toggle the breakpoint on the current line
|
||||||
|
"map \b <Action>(ToggleLineBreakpoint)
|
||||||
|
|
||||||
|
|
||||||
|
" Find more examples here: https://jb.gg/share-ideavimrc
|
||||||
|
|
||||||
|
" https://github.com/ville6000/dotfiles/blob/main/vimrc
|
||||||
|
set nocompatible " disable compatibility mode with vi
|
||||||
|
filetype off " disable filetype detection (but re-enable later, see below)
|
||||||
|
|
||||||
|
set encoding=utf-8 " UTF-8
|
||||||
|
set number " Show line numbers
|
||||||
|
set laststatus=2 " Always show statusline (even with only single window)
|
||||||
|
set showmatch " Highlight matching brace
|
||||||
|
set visualbell " Use visual bell (no beeping)
|
||||||
|
set hlsearch " Highlight all search results
|
||||||
|
set smartcase " Enable smart-case search
|
||||||
|
set ignorecase " Always case-insensitive
|
||||||
|
set incsearch " Searches for strings incrementally
|
||||||
|
set cindent " Use 'C' style program indenting
|
||||||
|
set expandtab " Use spaces instead of tabs
|
||||||
|
set shiftwidth=4 " Number of auto-indent spaces
|
||||||
|
set smartindent " Enable smart-indent
|
||||||
|
set smarttab " Enable smart-tabs
|
||||||
|
set softtabstop=4 " Number of spaces per Tab
|
||||||
|
set ruler " Show row and column ruler information
|
||||||
|
set cursorline " Highlight current line
|
||||||
|
set undolevels=1000 " Number of undo levels
|
||||||
|
set backspace=indent,eol,start " Backspace behaviour
|
||||||
|
set so=5
|
||||||
|
|
||||||
|
" move vertically by visual line (don't skip wrapped lines)
|
||||||
|
nmap j gj
|
||||||
|
nmap k gk
|
||||||
|
|
||||||
|
syntax enable
|
||||||
|
filetype plugin indent on
|
||||||
|
|
||||||
|
call plug#begin('~/.vim/plugged')
|
||||||
|
|
||||||
|
Plug 'ayu-theme/ayu-vim'
|
||||||
|
Plug 'ctrlpvim/ctrlp.vim'
|
||||||
|
|
||||||
|
call plug#end()
|
||||||
|
|
||||||
|
set termguicolors
|
||||||
|
set background=dark
|
||||||
|
let ayucolor="dark"
|
||||||
|
colorscheme ayu
|
||||||
|
|
||||||
|
if has('gui_running')
|
||||||
|
set macligatures
|
||||||
|
set guifont=JetBrainsMono:h14
|
||||||
|
endif
|
||||||
328
config/irssi/config
Normal file
328
config/irssi/config
Normal file
@@ -0,0 +1,328 @@
|
|||||||
|
# vim:noext ft=conf;
|
||||||
|
servers = (
|
||||||
|
{
|
||||||
|
address = "irc.cc.tut.fi";
|
||||||
|
chatnet = "IRCNet";
|
||||||
|
port = "6667";
|
||||||
|
own_host = "kapsi.fi";
|
||||||
|
family = "inet";
|
||||||
|
autoconnect = "no";
|
||||||
|
},
|
||||||
|
{ address = "irc.dal.net"; chatnet = "DALnet"; port = "6667"; },
|
||||||
|
{
|
||||||
|
address = "ssl.efnet.org";
|
||||||
|
chatnet = "EFNet";
|
||||||
|
port = "9999";
|
||||||
|
use_tls = "yes";
|
||||||
|
tls_verify = "no";
|
||||||
|
},
|
||||||
|
{
|
||||||
|
address = "irc.esper.net";
|
||||||
|
chatnet = "EsperNet";
|
||||||
|
port = "6697";
|
||||||
|
use_tls = "yes";
|
||||||
|
tls_verify = "yes";
|
||||||
|
},
|
||||||
|
{
|
||||||
|
address = "irc.libera.chat";
|
||||||
|
chatnet = "liberachat";
|
||||||
|
port = "6697";
|
||||||
|
use_tls = "yes";
|
||||||
|
tls_verify = "yes";
|
||||||
|
},
|
||||||
|
{
|
||||||
|
address = "irc.gamesurge.net";
|
||||||
|
chatnet = "GameSurge";
|
||||||
|
port = "6667";
|
||||||
|
},
|
||||||
|
{
|
||||||
|
address = "ssl.ircnet.ovh";
|
||||||
|
chatnet = "IRCnet";
|
||||||
|
port = "6697";
|
||||||
|
use_tls = "yes";
|
||||||
|
tls_verify = "yes";
|
||||||
|
},
|
||||||
|
{ address = "open.ircnet.net"; chatnet = "IRCnet"; port = "6667"; },
|
||||||
|
{
|
||||||
|
address = "irc.ircsource.net";
|
||||||
|
chatnet = "IRCSource";
|
||||||
|
port = "6667";
|
||||||
|
},
|
||||||
|
{ address = "irc.netfuze.net"; chatnet = "NetFuze"; port = "6667"; },
|
||||||
|
{
|
||||||
|
address = "irc.oftc.net";
|
||||||
|
chatnet = "OFTC";
|
||||||
|
port = "6697";
|
||||||
|
use_tls = "yes";
|
||||||
|
tls_verify = "yes";
|
||||||
|
},
|
||||||
|
{
|
||||||
|
address = "irc.quakenet.org";
|
||||||
|
chatnet = "QuakeNet";
|
||||||
|
port = "6667";
|
||||||
|
},
|
||||||
|
{
|
||||||
|
address = "irc.rizon.net";
|
||||||
|
chatnet = "Rizon";
|
||||||
|
port = "6697";
|
||||||
|
use_tls = "yes";
|
||||||
|
tls_verify = "yes";
|
||||||
|
},
|
||||||
|
{ address = "silc.silcnet.org"; chatnet = "SILC"; port = "706"; },
|
||||||
|
{
|
||||||
|
address = "irc.undernet.org";
|
||||||
|
chatnet = "Undernet";
|
||||||
|
port = "6667";
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
|
chatnets = {
|
||||||
|
DALnet = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "4";
|
||||||
|
max_msgs = "20";
|
||||||
|
max_whois = "30";
|
||||||
|
};
|
||||||
|
EFNet = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "4";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
EsperNet = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "4";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
liberachat = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "4";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
GameSurge = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "1";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
IRCnet = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "1";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
IRCSource = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "4";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
NetFuze = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "1";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
OFTC = { type = "IRC"; max_kicks = "1"; max_msgs = "1"; max_whois = "1"; };
|
||||||
|
QuakeNet = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "1";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
Rizon = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "1";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
SILC = { type = "SILC"; };
|
||||||
|
Undernet = {
|
||||||
|
type = "IRC";
|
||||||
|
max_kicks = "1";
|
||||||
|
max_msgs = "1";
|
||||||
|
max_whois = "1";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
channels = (
|
||||||
|
{ name = "#lobby"; chatnet = "EsperNet"; autojoin = "No"; },
|
||||||
|
{ name = "#libera"; chatnet = "liberachat"; autojoin = "No"; },
|
||||||
|
{ name = "#irssi"; chatnet = "liberachat"; autojoin = "No"; },
|
||||||
|
{ name = "#gamesurge"; chatnet = "GameSurge"; autojoin = "No"; },
|
||||||
|
{ name = "#irssi"; chatnet = "IRCNet"; autojoin = "No"; },
|
||||||
|
{ name = "#ircsource"; chatnet = "IRCSource"; autojoin = "No"; },
|
||||||
|
{ name = "#netfuze"; chatnet = "NetFuze"; autojoin = "No"; },
|
||||||
|
{ name = "#oftc"; chatnet = "OFTC"; autojoin = "No"; },
|
||||||
|
{ name = "silc"; chatnet = "SILC"; autojoin = "No"; }
|
||||||
|
);
|
||||||
|
|
||||||
|
aliases = {
|
||||||
|
ATAG = "WINDOW SERVER";
|
||||||
|
ADDALLCHANS = "SCRIPT EXEC foreach my \\$channel (Irssi::channels()) { Irssi::command(\"CHANNEL ADD -auto \\$channel->{visible_name} \\$channel->{server}->{tag} \\$channel->{key}\")\\;}";
|
||||||
|
B = "BAN";
|
||||||
|
BACK = "AWAY";
|
||||||
|
BANS = "BAN";
|
||||||
|
BYE = "QUIT";
|
||||||
|
C = "CLEAR";
|
||||||
|
CALC = "EXEC - if command -v bc >/dev/null 2>&1\\; then printf '%s=' '$*'\\; echo '$*' | bc -l\\; else echo bc was not found\\; fi";
|
||||||
|
CHAT = "DCC CHAT";
|
||||||
|
CS = "QUOTE CS";
|
||||||
|
DATE = "TIME";
|
||||||
|
DEHIGHLIGHT = "DEHILIGHT";
|
||||||
|
DESCRIBE = "ACTION";
|
||||||
|
DHL = "DEHILIGHT";
|
||||||
|
EXEMPTLIST = "MODE $C +e";
|
||||||
|
EXIT = "QUIT";
|
||||||
|
GOTO = "SCROLLBACK GOTO";
|
||||||
|
HIGHLIGHT = "HILIGHT";
|
||||||
|
HL = "HILIGHT";
|
||||||
|
HOST = "USERHOST";
|
||||||
|
INVITELIST = "MODE $C +I";
|
||||||
|
J = "JOIN";
|
||||||
|
K = "KICK";
|
||||||
|
KB = "KICKBAN";
|
||||||
|
KN = "KNOCKOUT";
|
||||||
|
LAST = "LASTLOG";
|
||||||
|
LEAVE = "PART";
|
||||||
|
M = "MSG";
|
||||||
|
MS = "QUOTE MS";
|
||||||
|
MUB = "UNBAN *";
|
||||||
|
N = "NAMES";
|
||||||
|
NMSG = "^MSG";
|
||||||
|
NS = "QUOTE NS";
|
||||||
|
OS = "QUOTE OS";
|
||||||
|
P = "PART";
|
||||||
|
Q = "QUERY";
|
||||||
|
RESET = "SET -default";
|
||||||
|
RUN = "SCRIPT LOAD";
|
||||||
|
SAY = "MSG *";
|
||||||
|
SB = "SCROLLBACK";
|
||||||
|
SBAR = "STATUSBAR";
|
||||||
|
SHELP = "QUOTE HELP";
|
||||||
|
SIGNOFF = "QUIT";
|
||||||
|
SV = "MSG * Irssi $J ($V) - https://irssi.org";
|
||||||
|
T = "TOPIC";
|
||||||
|
UB = "UNBAN";
|
||||||
|
UMODE = "MODE $N";
|
||||||
|
UNSET = "SET -clear";
|
||||||
|
W = "WHO";
|
||||||
|
WC = "WINDOW CLOSE";
|
||||||
|
WG = "WINDOW GOTO";
|
||||||
|
WJOIN = "JOIN -window";
|
||||||
|
WI = "WHOIS";
|
||||||
|
WII = "WHOIS $0 $0";
|
||||||
|
WL = "WINDOW LIST";
|
||||||
|
WN = "WINDOW NEW HIDDEN";
|
||||||
|
WQUERY = "QUERY -window";
|
||||||
|
WW = "WHOWAS";
|
||||||
|
};
|
||||||
|
|
||||||
|
statusbar = {
|
||||||
|
|
||||||
|
items = {
|
||||||
|
|
||||||
|
barstart = "{sbstart}";
|
||||||
|
barend = "{sbend}";
|
||||||
|
|
||||||
|
topicbarstart = "{topicsbstart}";
|
||||||
|
topicbarend = "{topicsbend}";
|
||||||
|
|
||||||
|
time = "{sb $Z}";
|
||||||
|
user = "{sb {sbnickmode $cumode}$N{sbmode $usermode}{sbaway $A}}";
|
||||||
|
|
||||||
|
window = "{sb $winref:$tag/$itemname{sbmode $M}}";
|
||||||
|
window_empty = "{sb $winref{sbservertag $tag}}";
|
||||||
|
|
||||||
|
prompt = "{prompt $[.15]itemname}";
|
||||||
|
prompt_empty = "{prompt $winname}";
|
||||||
|
|
||||||
|
topic = " $topic";
|
||||||
|
topic_empty = " Irssi v$J - https://irssi.org";
|
||||||
|
|
||||||
|
lag = "{sb Lag: $0-}";
|
||||||
|
act = "{sb Act: $0-}";
|
||||||
|
more = "-- more --";
|
||||||
|
};
|
||||||
|
|
||||||
|
default = {
|
||||||
|
|
||||||
|
window = {
|
||||||
|
|
||||||
|
disabled = "no";
|
||||||
|
type = "window";
|
||||||
|
placement = "bottom";
|
||||||
|
position = "1";
|
||||||
|
visible = "active";
|
||||||
|
|
||||||
|
items = {
|
||||||
|
barstart = { priority = "100"; };
|
||||||
|
time = { };
|
||||||
|
user = { };
|
||||||
|
window = { };
|
||||||
|
window_empty = { };
|
||||||
|
lag = { priority = "-1"; };
|
||||||
|
act = { priority = "10"; };
|
||||||
|
more = { priority = "-1"; alignment = "right"; };
|
||||||
|
barend = { priority = "100"; alignment = "right"; };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
window_inact = {
|
||||||
|
|
||||||
|
type = "window";
|
||||||
|
placement = "bottom";
|
||||||
|
position = "1";
|
||||||
|
visible = "inactive";
|
||||||
|
|
||||||
|
items = {
|
||||||
|
barstart = { priority = "100"; };
|
||||||
|
window = { };
|
||||||
|
window_empty = { };
|
||||||
|
more = { priority = "-1"; alignment = "right"; };
|
||||||
|
barend = { priority = "100"; alignment = "right"; };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
prompt = {
|
||||||
|
|
||||||
|
type = "root";
|
||||||
|
placement = "bottom";
|
||||||
|
position = "100";
|
||||||
|
visible = "always";
|
||||||
|
|
||||||
|
items = {
|
||||||
|
prompt = { priority = "-1"; };
|
||||||
|
prompt_empty = { priority = "-1"; };
|
||||||
|
input = { priority = "10"; };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
topic = {
|
||||||
|
|
||||||
|
type = "root";
|
||||||
|
placement = "top";
|
||||||
|
position = "1";
|
||||||
|
visible = "always";
|
||||||
|
|
||||||
|
items = {
|
||||||
|
topicbarstart = { priority = "100"; };
|
||||||
|
topic = { };
|
||||||
|
topic_empty = { };
|
||||||
|
topicbarend = { priority = "100"; alignment = "right"; };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
settings = {
|
||||||
|
core = {
|
||||||
|
real_name = "Ismo Vuorinen";
|
||||||
|
user_name = "ivuorinen";
|
||||||
|
nick = "ivuorinen";
|
||||||
|
};
|
||||||
|
"fe-common/core" = { theme = "lyynx"; };
|
||||||
|
"fe-text" = { actlist_sort = "refnum"; };
|
||||||
|
};
|
||||||
@@ -120,7 +120,7 @@ abstracts = {
|
|||||||
# the basic styling of how to print message, $0 = nick mode, $1 = nick
|
# the basic styling of how to print message, $0 = nick mode, $1 = nick
|
||||||
msgnick = "%K<%n$0$1-%K>%n %|";
|
msgnick = "%K<%n$0$1-%K>%n %|";
|
||||||
|
|
||||||
# message from you is printed. "msgownnick" specifies the styling of the
|
# message from you is printed. "ownnick" specifies the styling of the
|
||||||
# nick ($0 part in msgnick) and "ownmsgnick" specifies the styling of the
|
# nick ($0 part in msgnick) and "ownmsgnick" specifies the styling of the
|
||||||
# whole line.
|
# whole line.
|
||||||
|
|
||||||
@@ -251,6 +251,7 @@ abstracts = {
|
|||||||
# default background for all statusbars. You can also give
|
# default background for all statusbars. You can also give
|
||||||
# the default foreground color for statusbar items.
|
# the default foreground color for statusbar items.
|
||||||
sb_background = "%4%w";
|
sb_background = "%4%w";
|
||||||
|
window_border = "%4%w";
|
||||||
|
|
||||||
# default backround for "default" statusbar group
|
# default backround for "default" statusbar group
|
||||||
#sb_default_bg = "%4";
|
#sb_default_bg = "%4";
|
||||||
@@ -261,8 +262,8 @@ abstracts = {
|
|||||||
# background for topicbar (same default)
|
# background for topicbar (same default)
|
||||||
#sb_topic_bg = "%4";
|
#sb_topic_bg = "%4";
|
||||||
|
|
||||||
# text at the beginning of statusbars. sb-item already puts
|
# text at the beginning of statusbars. "sb" already puts a space there,
|
||||||
# space there,so we don't use anything by default.
|
# so we don't use anything by default.
|
||||||
sbstart = "";
|
sbstart = "";
|
||||||
# text at the end of statusbars. Use space so that it's never
|
# text at the end of statusbars. Use space so that it's never
|
||||||
# used for anything.
|
# used for anything.
|
||||||
258
config/irssi/lyynx.theme
Normal file
258
config/irssi/lyynx.theme
Normal file
@@ -0,0 +1,258 @@
|
|||||||
|
# LyyNx.theme
|
||||||
|
# started this by editing agon.theme, but later i noticed that there
|
||||||
|
# was nothing left from agon :)
|
||||||
|
# so here it is. i use it with transparent aterm, tint - lightblue,
|
||||||
|
# shading - 99, foreground - lightyellow
|
||||||
|
|
||||||
|
default_color = "-1";
|
||||||
|
info_eol = "false";
|
||||||
|
replaces = { "[]=" = "%K$*%n"; };
|
||||||
|
|
||||||
|
abstracts = {
|
||||||
|
##
|
||||||
|
## generic
|
||||||
|
##
|
||||||
|
|
||||||
|
# text to insert at the beginning of each non-message line
|
||||||
|
line_start = ". ";
|
||||||
|
|
||||||
|
# timestamp styling, nothing by default
|
||||||
|
timestamp = "%w$*%n";
|
||||||
|
|
||||||
|
# any kind of text that needs hilighting, default is to bold
|
||||||
|
hilight = "%_$*%_";
|
||||||
|
|
||||||
|
# any kind of error message, default is bright red
|
||||||
|
error = "%r$*%n";
|
||||||
|
|
||||||
|
# channel name is printed
|
||||||
|
channel = "%w$0-%n";
|
||||||
|
|
||||||
|
# nick is printed
|
||||||
|
nick = "%_%n$*%_";
|
||||||
|
|
||||||
|
# nick host is printed
|
||||||
|
nickhost = "$*";
|
||||||
|
|
||||||
|
# server name is printed
|
||||||
|
server = "%_$*%_";
|
||||||
|
|
||||||
|
# some kind of comment is printed
|
||||||
|
comment = "$*";
|
||||||
|
|
||||||
|
# reason for something is printed (part, quit, kick, ..)
|
||||||
|
reason = "{comment}";
|
||||||
|
|
||||||
|
# mode change is printed ([+o nick])
|
||||||
|
mode = "{comment $*}";
|
||||||
|
|
||||||
|
##
|
||||||
|
## channel specific messages
|
||||||
|
##
|
||||||
|
|
||||||
|
# highlighted nick/host is printed (joins)
|
||||||
|
channick_hilight = "%c$0-%n";
|
||||||
|
chanhost_hilight = "{nickhost %w$0-%n}";
|
||||||
|
|
||||||
|
# nick/host is printed (parts, quits, etc.)
|
||||||
|
channick = "%c$*";
|
||||||
|
chanhost = "%w{nickhost $*}";
|
||||||
|
|
||||||
|
# highlighted channel name is printed
|
||||||
|
channelhilight = "%n$*%n";
|
||||||
|
|
||||||
|
# ban/ban exception/invite list mask is printed
|
||||||
|
ban = "%n$*%n";
|
||||||
|
|
||||||
|
##
|
||||||
|
## messages
|
||||||
|
##
|
||||||
|
|
||||||
|
# the basic styling of how to print message, $0 = nick mode, $1 = nick
|
||||||
|
msgnick = "%_%n$0%n$1-%w:%n ";
|
||||||
|
|
||||||
|
# message from you is printed. "msgownnick" specifies the styling of the
|
||||||
|
# nick ($0 part in msgnick) and "ownmsgnick" specifies the styling of the
|
||||||
|
# whole line.
|
||||||
|
|
||||||
|
# Example1: You want the message text to be green:
|
||||||
|
# ownmsgnick = "{msgnick $0 $1-}%g";
|
||||||
|
# Example2.1: You want < and> chars to be yellow:
|
||||||
|
# ownmsgnick = "%Y{msgnick $0 $1-%Y}%n";
|
||||||
|
# (you'll also have to remove <> from replaces list above)
|
||||||
|
# Example2.2: But you still want to keep <> grey for other messages:
|
||||||
|
# pubmsgnick = "%K{msgnick $0 $1-%K}%n";
|
||||||
|
# pubmsgmenick = "%K{msgnick $0 $1-%K}%n";
|
||||||
|
# pubmsghinick = "%K{msgnick $1 $0$2-%n%K}%n";
|
||||||
|
# ownprivmsgnick = "%K{msgnick $*%K}%n";
|
||||||
|
# privmsgnick = "%K{msgnick %R$*%K}%n";
|
||||||
|
|
||||||
|
# $0 = nick mod, $1 = nick
|
||||||
|
ownmsgnick = "%n{msgnick %n$0$1-%n}%w";
|
||||||
|
ownnick = "%w$*%n";
|
||||||
|
|
||||||
|
# public message in channel, $0 = nick mode, $1 = nick
|
||||||
|
pubmsgnick = "{msgnick %n$0 %b$1-}";
|
||||||
|
pubnick = "%w$*%n";
|
||||||
|
|
||||||
|
# public message in channel meant for me, $0 = nick mode, $1 = nick
|
||||||
|
pubmsgmenick = "{msgnick $0 $1-}";
|
||||||
|
menick = "%w$*";
|
||||||
|
|
||||||
|
# public highlighted message in channel
|
||||||
|
# $0 = highlight color, $1 = nick mode, $2 = nick
|
||||||
|
pubmsghinick = "{msgnick $1 $0$2-%n}";
|
||||||
|
|
||||||
|
# channel name is printed with message
|
||||||
|
msgchannel = "%K:%c$*%n";
|
||||||
|
|
||||||
|
# private message, $0 = nick, $1 = host
|
||||||
|
privmsg = "[%n$0%K(%W$1-%K)%n] ";
|
||||||
|
|
||||||
|
# private message from you, $0 = "msg", $1 = target nick
|
||||||
|
ownprivmsg = "[%n$0%K(%n$1-%K)%n] ";
|
||||||
|
|
||||||
|
# own private message in query
|
||||||
|
ownprivmsgnick = "{msgnick $*}%W";
|
||||||
|
ownprivnick = "%n$*%W";
|
||||||
|
|
||||||
|
# private message in query
|
||||||
|
privmsgnick = "{msgnick $*}";
|
||||||
|
|
||||||
|
##
|
||||||
|
## Actions (/ME stuff)
|
||||||
|
##
|
||||||
|
|
||||||
|
# used internally by this theme
|
||||||
|
action_core = "%c * $*";
|
||||||
|
|
||||||
|
# generic one that's used by most actions
|
||||||
|
action = "{action_core $*} ";
|
||||||
|
|
||||||
|
# own action, both private/public
|
||||||
|
ownaction = "{action $*}";
|
||||||
|
|
||||||
|
# own action with target, both private/public
|
||||||
|
ownaction_target = "{action_core $0}%K:%c$1%n ";
|
||||||
|
|
||||||
|
# private action sent by others
|
||||||
|
pvtaction = "%W (*) $*%n ";
|
||||||
|
pvtaction_query = "{action $*}";
|
||||||
|
|
||||||
|
# public action sent by others
|
||||||
|
pubaction = "{action $*}";
|
||||||
|
|
||||||
|
|
||||||
|
##
|
||||||
|
## other IRC events
|
||||||
|
##
|
||||||
|
|
||||||
|
# whois
|
||||||
|
whois = "$[8]0: $1-";
|
||||||
|
|
||||||
|
# notices
|
||||||
|
ownnotice = "[%n$0%K(%R$1-%K)]%n ";
|
||||||
|
notice = "%K-%C$*%K-%n ";
|
||||||
|
pubnotice_channel = "%K:%m$*";
|
||||||
|
pvtnotice_host = "%K(%m$*%K)";
|
||||||
|
servernotice = "%g!$*%n ";
|
||||||
|
|
||||||
|
# CTCPs
|
||||||
|
ownctcp = "[%y$0%K(%n$1-%K)] ";
|
||||||
|
ctcp = "%Y$*%n";
|
||||||
|
|
||||||
|
# wallops
|
||||||
|
wallop = "%W$*%n: ";
|
||||||
|
wallop_nick = "%n$*";
|
||||||
|
wallop_action = "%W * $*%n ";
|
||||||
|
|
||||||
|
# netsplits
|
||||||
|
netsplit = "%n$*%n";
|
||||||
|
netjoin = "%C$*%n";
|
||||||
|
|
||||||
|
# /names list
|
||||||
|
names_prefix = "";
|
||||||
|
names_nick = "%_$0%_$1- ";
|
||||||
|
names_nick_op = "{names_nick $*}";
|
||||||
|
names_nick_halfop = "{names_nick $*}";
|
||||||
|
names_nick_voice = "{names_nick $*}";
|
||||||
|
names_users = "%c$*%n";
|
||||||
|
names_channel = "%C$*%n";
|
||||||
|
|
||||||
|
# DCC
|
||||||
|
dcc = "%g$*%n";
|
||||||
|
dccfile = "%_$*%_";
|
||||||
|
|
||||||
|
# DCC chat, own msg/action
|
||||||
|
dccownmsg = "[%n$0%K($1-%K)%n] ";
|
||||||
|
dccownnick = "%n$*%n";
|
||||||
|
dccownquerynick = "%W$*%n";
|
||||||
|
dccownaction = "{action $*}";
|
||||||
|
dccownaction_target = "{action_core $0}%K:%c$1%n ";
|
||||||
|
|
||||||
|
# DCC chat, others
|
||||||
|
dccmsg = "[%G$1-%K(%g$0%K)%n] ";
|
||||||
|
dccquerynick = "%G$*%n";
|
||||||
|
dccaction = "%W (*dcc*) $*%n %|";
|
||||||
|
|
||||||
|
##
|
||||||
|
## statusbar
|
||||||
|
##
|
||||||
|
|
||||||
|
# default background for all statusbars. You can also give
|
||||||
|
# the default foreground color for statusbar items.
|
||||||
|
sb_background = "%N%w";
|
||||||
|
|
||||||
|
# default backround for "default" statusbar group
|
||||||
|
#sb_default_bg = "%4";
|
||||||
|
# background for prompt / input line
|
||||||
|
sb_prompt_bg = "%n";
|
||||||
|
# background for info statusbar
|
||||||
|
sb_info_bg = "%8";
|
||||||
|
# background for topicbar (same default)
|
||||||
|
#sb_topic_bg = "%4";
|
||||||
|
|
||||||
|
# text at the beginning of statusbars. sb-item already puts
|
||||||
|
# space there,so we don't use anything by default.
|
||||||
|
sbstart = "";
|
||||||
|
# text at the end of statusbars. Use space so that it's never
|
||||||
|
# used for anything.
|
||||||
|
sbend = " ";
|
||||||
|
|
||||||
|
topicsbstart = "{sbstart $*}";
|
||||||
|
topicsbend = "{sbend $*}";
|
||||||
|
|
||||||
|
prompt = "$* ";
|
||||||
|
|
||||||
|
sb = " %n$*%n";
|
||||||
|
sbmode = "";
|
||||||
|
#sbaway = " (%g[away]%n)";
|
||||||
|
sbservertag = " $0";
|
||||||
|
sbnickmode = "$0";
|
||||||
|
|
||||||
|
# activity in statusbar
|
||||||
|
|
||||||
|
# ',' separator
|
||||||
|
sb_act_sep = "%K$*";
|
||||||
|
# normal text
|
||||||
|
sb_act_text = "%w$*";
|
||||||
|
# public message
|
||||||
|
sb_act_msg = "%c$*";
|
||||||
|
# hilight
|
||||||
|
sb_act_hilight = "%C$*";
|
||||||
|
# hilight with specified color, $0 = color, $1 = text
|
||||||
|
sb_act_hilight_color = "$0$1-%n";
|
||||||
|
};
|
||||||
|
formats = {
|
||||||
|
"fe-common/core" = {
|
||||||
|
join = "%g{channick $0} {chanhost $1} %cgot in {channel $2}";
|
||||||
|
part = "%g{channick $0} {chanhost $1} %cgot out of%n $2";
|
||||||
|
kick = "%g{channick $2} kicked %g{channick $0} ($3)";
|
||||||
|
quit = "%g{channick $0} {chanhost $1} %cleft irc%n ($2)";
|
||||||
|
line_start_irssi = "{line_start}";
|
||||||
|
nick_changed = "%g{channick $0} --> {channick $1}";
|
||||||
|
new_topic = "%g{nick $0} topic change -> {channel $1} to: $2";
|
||||||
|
endofnames = "$1 nicks totaly - $2 ops, $3 voices and $4 normal";
|
||||||
|
timestamp = "{timestamp %%H:%%M:%%S} ";
|
||||||
|
};
|
||||||
|
};
|
||||||
129
config/irssi/scripts/autorun/autoaway.pl
Normal file
129
config/irssi/scripts/autorun/autoaway.pl
Normal file
@@ -0,0 +1,129 @@
|
|||||||
|
# /AUTOAWAY <n> - Mark user away after <n> seconds of inactivity
|
||||||
|
# /AWAY - play nice with autoaway
|
||||||
|
# New, brighter, whiter version of my autoaway script. Actually works :)
|
||||||
|
# (c) 2000 Larry Daffner (vizzie@airmail.net)
|
||||||
|
# You may freely use, modify and distribute this script, as long as
|
||||||
|
# 1) you leave this notice intact
|
||||||
|
# 2) you don't pretend my code is yours
|
||||||
|
# 3) you don't pretend your code is mine
|
||||||
|
#
|
||||||
|
# share and enjoy!
|
||||||
|
|
||||||
|
# A simple script. /autoaway <n> will mark you as away automatically if
|
||||||
|
# you have not typed any commands in <n> seconds. (<n>=0 disables the feature)
|
||||||
|
# It will also automatically unmark you away the next time you type a command.
|
||||||
|
# Note that using the /away command will disable the autoaway mechanism, as
|
||||||
|
# well as the autoreturn. (when you unmark yourself, the autoaway wil
|
||||||
|
# restart again)
|
||||||
|
|
||||||
|
# Thanks to Adam Monsen for multiserver and config file fix
|
||||||
|
|
||||||
|
use strict;
|
||||||
|
use Irssi;
|
||||||
|
use Irssi::Irc;
|
||||||
|
|
||||||
|
use vars qw($VERSION %IRSSI);
|
||||||
|
$VERSION = "0.5";
|
||||||
|
%IRSSI = (
|
||||||
|
authors => 'Larry "Vizzie" Daffner',
|
||||||
|
contact => 'vizzie@airmail.net',
|
||||||
|
name => 'Automagic away setting',
|
||||||
|
description => 'Automatically goes away after defined inactivity',
|
||||||
|
license => 'BSD',
|
||||||
|
url => 'http://www.flamingpackets.net/~vizzie/irssi/',
|
||||||
|
changed => '2018-12-02',
|
||||||
|
);
|
||||||
|
|
||||||
|
my ($autoaway_sec, $autoaway_to_tag, $autoaway_state);
|
||||||
|
$autoaway_state = 0;
|
||||||
|
|
||||||
|
#
|
||||||
|
# /AUTOAWAY - set the autoaway timeout
|
||||||
|
#
|
||||||
|
sub cmd_autoaway {
|
||||||
|
my ($data, $server, $channel) = @_;
|
||||||
|
|
||||||
|
if (!($data =~ /^[0-9]+$/)) {
|
||||||
|
Irssi::print("autoaway: usage: /autoaway <seconds>");
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
$autoaway_sec = $data;
|
||||||
|
|
||||||
|
if ($autoaway_sec) {
|
||||||
|
Irssi::settings_set_int("autoaway_timeout", $autoaway_sec);
|
||||||
|
Irssi::print("autoaway timeout set to $autoaway_sec seconds");
|
||||||
|
} else {
|
||||||
|
Irssi::print("autoway disabled");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (defined($autoaway_to_tag)) {
|
||||||
|
Irssi::timeout_remove($autoaway_to_tag);
|
||||||
|
$autoaway_to_tag = undef;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($autoaway_sec) {
|
||||||
|
$autoaway_to_tag =
|
||||||
|
Irssi::timeout_add($autoaway_sec*1000, "auto_timeout", "");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#
|
||||||
|
# away = Set us away or back, within the autoaway system
|
||||||
|
sub cmd_away {
|
||||||
|
my ($data, $server, $channel) = @_;
|
||||||
|
|
||||||
|
if ($data eq "") {
|
||||||
|
$autoaway_state = 0;
|
||||||
|
} else {
|
||||||
|
if ($autoaway_state eq 0) {
|
||||||
|
Irssi::timeout_remove($autoaway_to_tag);
|
||||||
|
$autoaway_to_tag = undef;
|
||||||
|
$autoaway_state = 2;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub auto_timeout {
|
||||||
|
my ($data, $server) = @_;
|
||||||
|
|
||||||
|
# we're in the process.. don't touch anything.
|
||||||
|
$autoaway_state = 3;
|
||||||
|
foreach my $server (Irssi::servers()) {
|
||||||
|
$server->command("/AWAY autoaway after $autoaway_sec seconds");
|
||||||
|
}
|
||||||
|
|
||||||
|
Irssi::timeout_remove($autoaway_to_tag);
|
||||||
|
$autoaway_state = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
sub reset_timer {
|
||||||
|
if ($autoaway_state eq 1) {
|
||||||
|
$autoaway_state = 3;
|
||||||
|
foreach my $server (Irssi::servers()) {
|
||||||
|
$server->command("/AWAY");
|
||||||
|
}
|
||||||
|
|
||||||
|
$autoaway_state = 0;
|
||||||
|
}
|
||||||
|
if ($autoaway_state eq 0) {
|
||||||
|
if (defined($autoaway_to_tag)) {
|
||||||
|
Irssi::timeout_remove($autoaway_to_tag);
|
||||||
|
$autoaway_to_tag = undef();
|
||||||
|
}
|
||||||
|
if ($autoaway_sec) {
|
||||||
|
$autoaway_to_tag = Irssi::timeout_add($autoaway_sec*1000, "auto_timeout", "");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Irssi::settings_add_int("misc", "autoaway_timeout", 0);
|
||||||
|
|
||||||
|
$autoaway_sec = Irssi::settings_get_int("autoaway_timeout");
|
||||||
|
reset_timer();
|
||||||
|
|
||||||
|
Irssi::command_bind('autoaway', 'cmd_autoaway');
|
||||||
|
Irssi::command_bind('away', 'cmd_away');
|
||||||
|
Irssi::signal_add('send command', 'reset_timer');
|
||||||
|
|
||||||
|
# vim:set expandtab ts=2 sw=2:
|
||||||
39
config/irssi/scripts/autorun/autowhois.pl
Normal file
39
config/irssi/scripts/autorun/autowhois.pl
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
# /WHOIS all the users who send you a private message.
|
||||||
|
# v1.1 for irssi 0.7.98 by Timo Sirainen
|
||||||
|
use strict;
|
||||||
|
use Irssi;
|
||||||
|
use vars qw($VERSION %IRSSI);
|
||||||
|
$VERSION = "1.1";
|
||||||
|
%IRSSI = (
|
||||||
|
authors => "Timo \'cras\' Sirainen",
|
||||||
|
contact => "tss\@iki.fi",
|
||||||
|
name => "autowhois",
|
||||||
|
description => "/WHOIS all the users who send you a private message.",
|
||||||
|
license => "Public Domain",
|
||||||
|
url => "http://irssi.org/",
|
||||||
|
changed => "2002-03-04T22:47+0100",
|
||||||
|
changes => "v1.1: don't /WHOIS if query exists for the nick already"
|
||||||
|
);
|
||||||
|
|
||||||
|
# History:
|
||||||
|
# v1.1: don't /WHOIS if query exists for the nick already
|
||||||
|
|
||||||
|
my ($lastfrom, $lastquery);
|
||||||
|
|
||||||
|
sub msg_private_first {
|
||||||
|
my ($server, $msg, $nick, $address) = @_;
|
||||||
|
|
||||||
|
$lastquery = $server->query_find($nick);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub msg_private {
|
||||||
|
my ($server, $msg, $nick, $address) = @_;
|
||||||
|
|
||||||
|
return if $lastquery || $lastfrom eq $nick;
|
||||||
|
|
||||||
|
$lastfrom = $nick;
|
||||||
|
$server->command("whois $nick");
|
||||||
|
}
|
||||||
|
|
||||||
|
Irssi::signal_add_first('message private', 'msg_private_first');
|
||||||
|
Irssi::signal_add('message private', 'msg_private');
|
||||||
115
config/irssi/scripts/autorun/go.pl
Normal file
115
config/irssi/scripts/autorun/go.pl
Normal file
@@ -0,0 +1,115 @@
|
|||||||
|
use strict;
|
||||||
|
use vars qw($VERSION %IRSSI);
|
||||||
|
use Irssi;
|
||||||
|
use Irssi::Irc;
|
||||||
|
|
||||||
|
# Usage:
|
||||||
|
# /script load go.pl
|
||||||
|
# If you are in #irssi you can type /go #irssi or /go irssi or even /go ir ...
|
||||||
|
# also try /go ir<tab> and /go <tab> (that's two spaces)
|
||||||
|
#
|
||||||
|
# The following settings exist:
|
||||||
|
#
|
||||||
|
# /SET go_match_case_sensitive [ON|OFF]
|
||||||
|
# Match window/item names sensitively (the default). Turning this off
|
||||||
|
# means e.g. "/go foo" would jump to a window named "Foobar", too.
|
||||||
|
#
|
||||||
|
# /SET go_match_anchored [ON|OFF]
|
||||||
|
# Match window/names only at the start of the word (the default). Turning
|
||||||
|
# this off will mean that strings can match anywhere in the window/names.
|
||||||
|
# The leading '#' of channel names is optional either way.
|
||||||
|
#
|
||||||
|
# /SET go_complete_case_sensitive [ON|OFF]
|
||||||
|
# When using tab-completion, match case-insensitively (the default).
|
||||||
|
# Turning this on means that "/go foo<tab>" will *not* suggest "Foobar".
|
||||||
|
#
|
||||||
|
# /SET go_complete_anchored [ON|OFF]
|
||||||
|
# Match window/names only at the start of the word. The default is 'off',
|
||||||
|
# which causes completion to match anywhere in the window/names during
|
||||||
|
# completion. The leading '#' of channel names is optional either way.
|
||||||
|
#
|
||||||
|
|
||||||
|
$VERSION = '1.1.1';
|
||||||
|
|
||||||
|
%IRSSI = (
|
||||||
|
authors => 'nohar',
|
||||||
|
contact => 'nohar@freenode',
|
||||||
|
name => 'go to window',
|
||||||
|
description => 'Implements /go command that activates a window given a name/partial name. It features a nice completion.',
|
||||||
|
license => 'GPLv2 or later',
|
||||||
|
changed => '2019-02-25'
|
||||||
|
);
|
||||||
|
|
||||||
|
sub _make_regexp {
|
||||||
|
my ($name, $ci, $aw) = @_;
|
||||||
|
my $re = "\Q${name}\E";
|
||||||
|
$re = "(?i:$re)" unless $ci;
|
||||||
|
$re = "^#?$re" if $aw;
|
||||||
|
return $re;
|
||||||
|
}
|
||||||
|
|
||||||
|
sub signal_complete_go {
|
||||||
|
my ($complist, $window, $word, $linestart, $want_space) = @_;
|
||||||
|
my $channel = $window->get_active_name();
|
||||||
|
my $k = Irssi::parse_special('$k');
|
||||||
|
|
||||||
|
return unless ($linestart =~ /^\Q${k}\Ego\b/i);
|
||||||
|
|
||||||
|
my $re = _make_regexp($word,
|
||||||
|
Irssi::settings_get_bool('go_complete_case_sensitive'),
|
||||||
|
Irssi::settings_get_bool('go_complete_anchored'));
|
||||||
|
@$complist = ();
|
||||||
|
foreach my $w (Irssi::windows) {
|
||||||
|
my $name = $w->get_active_name();
|
||||||
|
if ($word ne "") {
|
||||||
|
if ($name =~ $re) {
|
||||||
|
push(@$complist, $name)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
push(@$complist, $name);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Irssi::signal_stop();
|
||||||
|
};
|
||||||
|
|
||||||
|
sub cmd_go
|
||||||
|
{
|
||||||
|
my($chan,$server,$witem) = @_;
|
||||||
|
|
||||||
|
my $case_sensitive = Irssi::settings_get_bool('go_match_case_sensitive');
|
||||||
|
my $match_anchored = Irssi::settings_get_bool('go_match_anchored');
|
||||||
|
|
||||||
|
$chan =~ s/ *//g;
|
||||||
|
my $re = _make_regexp($chan, $case_sensitive, $match_anchored);
|
||||||
|
|
||||||
|
my @matches;
|
||||||
|
foreach my $w (Irssi::windows) {
|
||||||
|
my $name = $w->get_active_name();
|
||||||
|
if (($case_sensitive && $name eq $chan) ||
|
||||||
|
(!$case_sensitive && CORE::fc $name eq CORE::fc $chan)) {
|
||||||
|
$w->set_active();
|
||||||
|
return;
|
||||||
|
} elsif ($name =~ /$re/) {
|
||||||
|
push(@matches, $w);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (@matches) {
|
||||||
|
$matches[0]->set_active();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Irssi::command_bind("go", "cmd_go");
|
||||||
|
Irssi::signal_add_first('complete word', 'signal_complete_go');
|
||||||
|
Irssi::settings_add_bool('go', 'go_match_case_sensitive', 1);
|
||||||
|
Irssi::settings_add_bool('go', 'go_complete_case_sensitive', 0);
|
||||||
|
Irssi::settings_add_bool('go', 'go_match_anchored', 1);
|
||||||
|
Irssi::settings_add_bool('go', 'go_complete_anchored', 0);
|
||||||
|
|
||||||
|
# Changelog
|
||||||
|
#
|
||||||
|
# 2017-02-02 1.1 martin f. krafft <madduck@madduck.net>
|
||||||
|
# - made case-sensitivity of match configurable
|
||||||
|
# - made anchoring of search strings configurable
|
||||||
|
#
|
||||||
|
# 2019-02-025 1.1.1 dylan lloyd <dylan@disinclined.org>
|
||||||
|
# - prefer exact channel matches
|
||||||
113
config/irssi/scripts/autorun/highlite.pl
Normal file
113
config/irssi/scripts/autorun/highlite.pl
Normal file
@@ -0,0 +1,113 @@
|
|||||||
|
use strict;
|
||||||
|
use Irssi;
|
||||||
|
use Irssi::Irc;
|
||||||
|
|
||||||
|
use vars qw($VERSION %IRSSI);
|
||||||
|
|
||||||
|
$VERSION = "1.0";
|
||||||
|
%IRSSI = (
|
||||||
|
"authors" => "Mantis",
|
||||||
|
"contact" => "mantis\@inta-link.com",
|
||||||
|
"name" => "highlite",
|
||||||
|
"description" => "shows events happening in all channels you are in that may concern you",
|
||||||
|
"url" => "http://www.inta-link.com/",
|
||||||
|
"license" => "GNU GPL v2",
|
||||||
|
"changed" => "2003-01-03"
|
||||||
|
);
|
||||||
|
|
||||||
|
sub msg_join
|
||||||
|
{
|
||||||
|
my ($server, $channame, $nick, $host) = @_;
|
||||||
|
$channame =~ s/^://;
|
||||||
|
|
||||||
|
my $windowname = Irssi::window_find_name('highlite');
|
||||||
|
$windowname->print("%B%0JOIN : " . $nick . " : " . $channame . " : " . $host, MSGLEVEL_CLIENTCRAP) if ($windowname);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub msg_part
|
||||||
|
{
|
||||||
|
my ($server, $channame, $nick, $host) = @_;
|
||||||
|
$channame =~ s/^://;
|
||||||
|
|
||||||
|
my $windowname = Irssi::window_find_name('highlite');
|
||||||
|
$windowname->print("%b%0PART : " . $nick . " : " . $channame . " : " . $host, MSGLEVEL_CLIENTCRAP) if ($windowname);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub msg_quit
|
||||||
|
{
|
||||||
|
my ($server, $nick, $host, $quitmsg) = @_;
|
||||||
|
|
||||||
|
if (substr($quitmsg, 0, 14) eq "Read error to ")
|
||||||
|
{
|
||||||
|
$quitmsg = "[ General Read Error ]";
|
||||||
|
}
|
||||||
|
if (substr($quitmsg, 0, 17) eq "Ping timeout for ")
|
||||||
|
{
|
||||||
|
$quitmsg = "[ General Ping Timeout Error ]";
|
||||||
|
}
|
||||||
|
|
||||||
|
my $windowname = Irssi::window_find_name('highlite');
|
||||||
|
$windowname->print("%R%0QUIT : " . $nick . " : " . $host . " : " . $quitmsg, MSGLEVEL_CLIENTCRAP) if ($windowname);
|
||||||
|
|
||||||
|
$quitmsg = "";
|
||||||
|
}
|
||||||
|
|
||||||
|
sub msg_topic
|
||||||
|
{
|
||||||
|
my ($server, $channame, $topicmsg, $nick, $host) = @_;
|
||||||
|
$channame =~ s/^://;
|
||||||
|
|
||||||
|
my $windowname = Irssi::window_find_name('highlite');
|
||||||
|
$windowname->print("%G%0TOPIC : " . $nick . " : " . $channame . " : " . $topicmsg, MSGLEVEL_CLIENTCRAP) if ($windowname);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub msg_nick
|
||||||
|
{
|
||||||
|
my ($server, $nick, $old_nick, $host) = @_;
|
||||||
|
|
||||||
|
my $windowname = Irssi::window_find_name('highlite');
|
||||||
|
$windowname->print("%m%0NICK : " . $old_nick . " : " . $nick . " : " . $host, MSGLEVEL_CLIENTCRAP) if ($windowname);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub msg_kick
|
||||||
|
{
|
||||||
|
my ($server, $channame, $kicked, $nick, $host, $reason) = @_;
|
||||||
|
$channame =~ s/^://;
|
||||||
|
|
||||||
|
my $windowname = Irssi::window_find_name('highlite');
|
||||||
|
$windowname->print("%Y%0KICK : " . $kicked . " : " . $channame . " : " . $nick . " : " . $reason, MSGLEVEL_CLIENTCRAP) if ($windowname);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub sig_printtext {
|
||||||
|
my ($dest, $text, $stripped) = @_;
|
||||||
|
|
||||||
|
if (($dest->{level} & (MSGLEVEL_HILIGHT|MSGLEVEL_MSGS)) && ($dest->{level} & MSGLEVEL_NOHILIGHT) == 0)
|
||||||
|
{
|
||||||
|
if ($dest->{level} & MSGLEVEL_PUBLIC)
|
||||||
|
{
|
||||||
|
my $windowname = Irssi::window_find_name('highlite');
|
||||||
|
|
||||||
|
$windowname->print("%W%0HIGHLITE : " . $dest->{target} . " : " . $text, MSGLEVEL_CLIENTCRAP) if ($windowname);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
my $windowname = Irssi::window_find_name('highlite');
|
||||||
|
if (!$windowname)
|
||||||
|
{
|
||||||
|
Irssi::command("window new hidden");
|
||||||
|
Irssi::command("window name highlite");
|
||||||
|
}
|
||||||
|
|
||||||
|
Irssi::signal_add(
|
||||||
|
{
|
||||||
|
'message join' => \&msg_join,
|
||||||
|
'message part' => \&msg_part,
|
||||||
|
'message quit' => \&msg_quit,
|
||||||
|
'message topic' => \&msg_topic,
|
||||||
|
'print text', 'sig_printtext',
|
||||||
|
'message nick' => \&msg_nick,
|
||||||
|
'message kick' => \&msg_kick
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
257
config/irssi/scripts/autorun/nickcolor.pl
Normal file
257
config/irssi/scripts/autorun/nickcolor.pl
Normal file
@@ -0,0 +1,257 @@
|
|||||||
|
use strict;
|
||||||
|
use Irssi 20020101.0250 ();
|
||||||
|
use vars qw($VERSION %IRSSI);
|
||||||
|
$VERSION = "2.1";
|
||||||
|
%IRSSI = (
|
||||||
|
authors => "Timo Sirainen, Ian Peters, David Leadbeater, Bruno Cattáneo",
|
||||||
|
contact => "tss\@iki.fi",
|
||||||
|
name => "Nick Color",
|
||||||
|
description => "assign a different color for each nick",
|
||||||
|
license => "Public Domain",
|
||||||
|
url => "http://irssi.org/",
|
||||||
|
changed => "Mon 08 Jan 21:28:53 BST 2018",
|
||||||
|
);
|
||||||
|
|
||||||
|
# Tweaks to this plugin are:
|
||||||
|
# - Moved irssi folder under $XDG_CONFIG_HOME/irssi/
|
||||||
|
# - changed TABs to spaces
|
||||||
|
|
||||||
|
# Settings:
|
||||||
|
# nickcolor_colors: List of color codes to use.
|
||||||
|
# e.g. /set nickcolor_colors 2 3 4 5 6 7 9 10 11 12 13
|
||||||
|
# (avoid 8, as used for hilights in the default theme).
|
||||||
|
#
|
||||||
|
# nickcolor_enable_prefix: Enables prefix for same nick.
|
||||||
|
#
|
||||||
|
# nickcolor_enable_truncate: Enables nick truncation.
|
||||||
|
#
|
||||||
|
# nickcolor_prefix_text: Prefix text for succesive messages.
|
||||||
|
# e.g. /set nickcolor_prefix_text -
|
||||||
|
#
|
||||||
|
# nickcolor_truncate_value: Truncate nick value.
|
||||||
|
# e.g. /set nickcolor_truncate_value -7
|
||||||
|
# This will truncate nicknames at 7 characters and make them right aligned
|
||||||
|
|
||||||
|
my %saved_colors;
|
||||||
|
my %session_colors = {};
|
||||||
|
my %saved_nicks; # To store each channel's last nickname
|
||||||
|
|
||||||
|
sub load_colors {
|
||||||
|
open my $color_fh, "<", "$ENV{XDG_CONFIG_HOME}/irssi/saved_colors";
|
||||||
|
while (<$color_fh>) {
|
||||||
|
chomp;
|
||||||
|
my($nick, $color) = split ":";
|
||||||
|
$saved_colors{$nick} = $color;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub save_colors {
|
||||||
|
open COLORS, ">", "$ENV{XDG_CONFIG_HOME}/irssi/saved_colors";
|
||||||
|
|
||||||
|
foreach my $nick (keys %saved_colors) {
|
||||||
|
print COLORS "$nick:$saved_colors{$nick}\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
close COLORS;
|
||||||
|
}
|
||||||
|
|
||||||
|
# If someone we've colored (either through the saved colors, or the hash
|
||||||
|
# function) changes their nick, we'd like to keep the same color associated
|
||||||
|
# with them (but only in the session_colors, ie a temporary mapping).
|
||||||
|
|
||||||
|
sub sig_nick {
|
||||||
|
my ($server, $newnick, $nick, $address) = @_;
|
||||||
|
my $color;
|
||||||
|
|
||||||
|
$newnick = substr ($newnick, 1) if ($newnick =~ /^:/);
|
||||||
|
|
||||||
|
if ($color = $saved_colors{$nick}) {
|
||||||
|
$session_colors{$newnick} = $color;
|
||||||
|
} elsif ($color = $session_colors{$nick}) {
|
||||||
|
$session_colors{$newnick} = $color;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
# This gave reasonable distribution values when run across
|
||||||
|
# /usr/share/dict/words
|
||||||
|
|
||||||
|
sub simple_hash {
|
||||||
|
my ($string) = @_;
|
||||||
|
chomp $string;
|
||||||
|
my @chars = split //, $string;
|
||||||
|
my $counter;
|
||||||
|
|
||||||
|
foreach my $char (@chars) {
|
||||||
|
$counter += ord $char;
|
||||||
|
}
|
||||||
|
|
||||||
|
my @colors = split / /, Irssi::settings_get_str('nickcolor_colors');
|
||||||
|
$counter = $colors[$counter % @colors];
|
||||||
|
|
||||||
|
return $counter;
|
||||||
|
}
|
||||||
|
|
||||||
|
# process public (others) messages
|
||||||
|
sub sig_public {
|
||||||
|
my ($server, $msg, $nick, $address, $target) = @_;
|
||||||
|
|
||||||
|
my $enable_prefix = Irssi::settings_get_bool('nickcolor_enable_prefix');
|
||||||
|
my $enable_truncate = Irssi::settings_get_bool('nickcolor_enable_truncate');
|
||||||
|
my $prefix_text = Irssi::settings_get_str('nickcolor_prefix_text');
|
||||||
|
my $truncate_value = Irssi::settings_get_int('nickcolor_truncate_value');
|
||||||
|
|
||||||
|
# Reference for server/channel
|
||||||
|
my $tagtarget = "$server->{tag}/$target";
|
||||||
|
|
||||||
|
# Set default nick truncate value to 0 if option is disabled
|
||||||
|
$truncate_value = 0 if (!$enable_truncate);
|
||||||
|
|
||||||
|
# Has the user assigned this nick a color?
|
||||||
|
my $color = $saved_colors{$nick};
|
||||||
|
|
||||||
|
# Have -we- already assigned this nick a color?
|
||||||
|
if (!$color) {
|
||||||
|
$color = $session_colors{$nick};
|
||||||
|
}
|
||||||
|
|
||||||
|
# Let's assign this nick a color
|
||||||
|
if (!$color) {
|
||||||
|
$color = simple_hash $nick;
|
||||||
|
$session_colors{$nick} = $color;
|
||||||
|
}
|
||||||
|
|
||||||
|
$color = sprintf "\003%02d", $color;
|
||||||
|
|
||||||
|
# Optional: We check if it's the same nickname for current target
|
||||||
|
if ($saved_nicks{$tagtarget} eq $nick && $enable_prefix)
|
||||||
|
{
|
||||||
|
# Grouped message
|
||||||
|
Irssi::command('/^format pubmsg ' . $prefix_text . '$1');
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
# Normal message
|
||||||
|
Irssi::command('/^format pubmsg {pubmsgnick $2 {pubnick ' . $color . '$[' . $truncate_value . ']0}}$1');
|
||||||
|
|
||||||
|
# Save nickname for next message
|
||||||
|
$saved_nicks{$tagtarget} = $nick;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
# process public (me) messages
|
||||||
|
sub sig_me {
|
||||||
|
my ($server, $msg, $target) = @_;
|
||||||
|
my $nick = $server->{nick};
|
||||||
|
|
||||||
|
my $enable_prefix = Irssi::settings_get_bool('nickcolor_enable_prefix');
|
||||||
|
my $enable_truncate = Irssi::settings_get_bool('nickcolor_enable_truncate');
|
||||||
|
my $prefix_text = Irssi::settings_get_str('nickcolor_prefix_text');
|
||||||
|
my $truncate_value = Irssi::settings_get_int('nickcolor_truncate_value');
|
||||||
|
|
||||||
|
# Reference for server/channel
|
||||||
|
my $tagtarget = "$server->{tag}/$target";
|
||||||
|
|
||||||
|
# Set default nick truncate value to 0 if option is disabled
|
||||||
|
$truncate_value = 0 if (!$enable_truncate);
|
||||||
|
|
||||||
|
# Optional: We check if it's the same nickname for current target
|
||||||
|
if ($saved_nicks{$tagtarget} eq $nick && $enable_prefix)
|
||||||
|
{
|
||||||
|
# Grouped message
|
||||||
|
Irssi::command('/^format own_msg ' . $prefix_text . '$1');
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
# Normal message
|
||||||
|
Irssi::command('/^format own_msg {ownmsgnick $2 {ownnick $[' . $truncate_value . ']0}}$1');
|
||||||
|
|
||||||
|
# Save nickname for next message
|
||||||
|
$saved_nicks{$tagtarget} = $nick;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
# process public (others) actions
|
||||||
|
sub sig_action_public {
|
||||||
|
my ($server, $msg, $nick, $address, $target) = @_;
|
||||||
|
|
||||||
|
my $enable_prefix = Irssi::settings_get_bool('nickcolor_enable_prefix');
|
||||||
|
|
||||||
|
# Reference for server/channel
|
||||||
|
my $tagtarget = "$server->{tag}/$target";
|
||||||
|
|
||||||
|
# Empty current target nick if prefix option is enabled
|
||||||
|
$saved_nicks{$tagtarget} = '' if ($enable_prefix);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
# process public (me) actions
|
||||||
|
sub sig_action_me {
|
||||||
|
my ($server, $msg, $target) = @_;
|
||||||
|
my $nick = $server->{nick};
|
||||||
|
|
||||||
|
my $enable_prefix = Irssi::settings_get_bool('nickcolor_enable_prefix');
|
||||||
|
|
||||||
|
# Reference for server/channel
|
||||||
|
my $tagtarget = "$server->{tag}/$target";
|
||||||
|
|
||||||
|
# Empty current target nick if prefix option is enabled
|
||||||
|
$saved_nicks{$tagtarget} = '' if ($enable_prefix);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
sub cmd_color {
|
||||||
|
my ($data, $server, $witem) = @_;
|
||||||
|
my ($op, $nick, $color) = split " ", $data;
|
||||||
|
|
||||||
|
$op = lc $op;
|
||||||
|
|
||||||
|
if (!$op) {
|
||||||
|
Irssi::print ("No operation given (save/set/clear/list/preview)");
|
||||||
|
} elsif ($op eq "save") {
|
||||||
|
save_colors;
|
||||||
|
} elsif ($op eq "set") {
|
||||||
|
if (!$nick) {
|
||||||
|
Irssi::print ("Nick not given");
|
||||||
|
} elsif (!$color) {
|
||||||
|
Irssi::print ("Color not given");
|
||||||
|
} elsif ($color < 2 || $color > 14) {
|
||||||
|
Irssi::print ("Color must be between 2 and 14 inclusive");
|
||||||
|
} else {
|
||||||
|
$saved_colors{$nick} = $color;
|
||||||
|
}
|
||||||
|
} elsif ($op eq "clear") {
|
||||||
|
if (!$nick) {
|
||||||
|
Irssi::print ("Nick not given");
|
||||||
|
} else {
|
||||||
|
delete ($saved_colors{$nick});
|
||||||
|
}
|
||||||
|
} elsif ($op eq "list") {
|
||||||
|
Irssi::print ("\nSaved Colors:");
|
||||||
|
foreach my $nick (keys %saved_colors) {
|
||||||
|
Irssi::print (chr (3) . sprintf("%02d", $saved_colors{$nick}) . "$nick" .
|
||||||
|
chr (3) . "1 ($saved_colors{$nick})");
|
||||||
|
}
|
||||||
|
} elsif ($op eq "preview") {
|
||||||
|
Irssi::print ("\nAvailable colors:");
|
||||||
|
foreach my $i (2..14) {
|
||||||
|
Irssi::print (chr (3) . "$i" . "Color #$i");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
load_colors;
|
||||||
|
|
||||||
|
Irssi::settings_add_str('misc', 'nickcolor_colors', '2 3 4 5 6 7 9 10 11 12 13');
|
||||||
|
Irssi::settings_add_bool('misc', 'nickcolor_enable_prefix', 0);
|
||||||
|
Irssi::settings_add_bool('misc', 'nickcolor_enable_truncate', 0);
|
||||||
|
Irssi::settings_add_str('misc', 'nickcolor_prefix_text' => '- ');
|
||||||
|
Irssi::settings_add_int('misc', 'nickcolor_truncate_value' => 0);
|
||||||
|
Irssi::command_bind('color', 'cmd_color');
|
||||||
|
|
||||||
|
Irssi::signal_add('message public', 'sig_public');
|
||||||
|
Irssi::signal_add('message own_public', 'sig_me');
|
||||||
|
Irssi::signal_add('message irc action', 'sig_action_public');
|
||||||
|
Irssi::signal_add('message irc own_action', 'sig_action_me');
|
||||||
|
Irssi::signal_add('event nick', 'sig_nick');
|
||||||
606
config/irssi/scripts/autorun/trackbar.pl
Normal file
606
config/irssi/scripts/autorun/trackbar.pl
Normal file
@@ -0,0 +1,606 @@
|
|||||||
|
## trackbar.pl
|
||||||
|
#
|
||||||
|
# This little script will do just one thing: it will draw a line each time you
|
||||||
|
# switch away from a window. This way, you always know just upto where you've
|
||||||
|
# been reading that window :) It also removes the previous drawn line, so you
|
||||||
|
# don't see double lines.
|
||||||
|
#
|
||||||
|
# redraw trackbar only works on irssi 0.8.17 or higher.
|
||||||
|
#
|
||||||
|
##
|
||||||
|
|
||||||
|
## Usage:
|
||||||
|
#
|
||||||
|
# The script works right out of the box, but if you want you can change
|
||||||
|
# the working by /set'ing the following variables:
|
||||||
|
#
|
||||||
|
# Setting: trackbar_style
|
||||||
|
# Description: This setting will be the color of your trackbar line.
|
||||||
|
# By default the value will be '%K', only Irssi color
|
||||||
|
# formats are allowed. If you don't know the color formats
|
||||||
|
# by heart, you can take a look at the formats documentation.
|
||||||
|
# You will find the proper docs on http://www.irssi.org/docs.
|
||||||
|
#
|
||||||
|
# Setting: trackbar_string
|
||||||
|
# Description: This is the string that your line will display. This can
|
||||||
|
# be multiple characters or just one. For example: '~-~-'
|
||||||
|
# The default setting is '-'.
|
||||||
|
# Here are some unicode characters you can try:
|
||||||
|
# "───" => U+2500 => a line
|
||||||
|
# "═══" => U+2550 => a double line
|
||||||
|
# "━━━" => U+2501 => a wide line
|
||||||
|
# "▭ " => U+25ad => a white rectangle
|
||||||
|
#
|
||||||
|
# Setting: trackbar_use_status_window
|
||||||
|
# Description: If this setting is set to OFF, Irssi won't print a trackbar
|
||||||
|
# in the statuswindow
|
||||||
|
#
|
||||||
|
# Setting: trackbar_ignore_windows
|
||||||
|
# Description: A list of windows where no trackbar should be printed
|
||||||
|
#
|
||||||
|
# Setting: trackbar_print_timestamp
|
||||||
|
# Description: If this setting is set to ON, Irssi will print the formatted
|
||||||
|
# timestamp in front of the trackbar.
|
||||||
|
#
|
||||||
|
# Setting: trackbar_require_seen
|
||||||
|
# Description: Only clear the trackbar if it has been scrolled to.
|
||||||
|
#
|
||||||
|
# Setting: trackbar_all_manual
|
||||||
|
# Description: Never clear the trackbar until you do /mark.
|
||||||
|
#
|
||||||
|
# /mark is a command that will redraw the line at the bottom.
|
||||||
|
#
|
||||||
|
# Command: /trackbar, /trackbar goto
|
||||||
|
# Description: Jump to where the trackbar is, to pick up reading
|
||||||
|
#
|
||||||
|
# Command: /trackbar keep
|
||||||
|
# Description: Keep this window's trackbar where it is the next time
|
||||||
|
# you switch windows (then this flag is cleared again)
|
||||||
|
#
|
||||||
|
# Command: /mark, /trackbar mark
|
||||||
|
# Description: Remove the old trackbar and mark the bottom of this
|
||||||
|
# window with a new trackbar
|
||||||
|
#
|
||||||
|
# Command: /trackbar markvisible
|
||||||
|
# Description: Like mark for all visible windows
|
||||||
|
#
|
||||||
|
# Command: /trackbar markall
|
||||||
|
# Description: Like mark for all windows
|
||||||
|
#
|
||||||
|
# Command: /trackbar remove
|
||||||
|
# Description: Remove this window's trackbar
|
||||||
|
#
|
||||||
|
# Command: /trackbar removeall
|
||||||
|
# Description: Remove all windows' trackbars
|
||||||
|
#
|
||||||
|
# Command: /trackbar redraw
|
||||||
|
# Description: Force redraw of trackbars
|
||||||
|
#
|
||||||
|
##
|
||||||
|
|
||||||
|
##
|
||||||
|
#
|
||||||
|
# For bugreports and other improvements contact one of the authors.
|
||||||
|
#
|
||||||
|
# This program is free software; you can redistribute it and/or modify
|
||||||
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
# the Free Software Foundation; either version 2 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
# GNU General Public License for more details.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this script; if not, write to the Free Software
|
||||||
|
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
#
|
||||||
|
##
|
||||||
|
|
||||||
|
use strict;
|
||||||
|
use warnings;
|
||||||
|
use vars qw($VERSION %IRSSI);
|
||||||
|
|
||||||
|
$VERSION = "2.9"; # a4c78e85092a271
|
||||||
|
|
||||||
|
%IRSSI = (
|
||||||
|
authors => "Peter 'kinlo' Leurs, Uwe Dudenhoeffer, " .
|
||||||
|
"Michiel Holtkamp, Nico R. Wohlgemuth, " .
|
||||||
|
"Geert Hauwaerts",
|
||||||
|
contact => 'peter@pfoe.be',
|
||||||
|
patchers => 'Johan Kiviniemi (UTF-8), Uwe Dudenhoeffer (on-upgrade-remove-line)',
|
||||||
|
name => 'trackbar',
|
||||||
|
description => 'Shows a bar where you have last read a window.',
|
||||||
|
license => 'GNU General Public License',
|
||||||
|
url => 'http://www.pfoe.be/~peter/trackbar/',
|
||||||
|
commands => 'trackbar',
|
||||||
|
);
|
||||||
|
|
||||||
|
## Comments and remarks.
|
||||||
|
#
|
||||||
|
# This script uses settings.
|
||||||
|
# Use /SET to change the value or /TOGGLE to switch it on or off.
|
||||||
|
#
|
||||||
|
#
|
||||||
|
# Tip: The command 'trackbar' is very useful if you bind that to a key,
|
||||||
|
# so you can easily jump to the trackbar. Please see 'help bind' for
|
||||||
|
# more information about keybindings in Irssi.
|
||||||
|
#
|
||||||
|
# Command: /BIND meta2-P key F1
|
||||||
|
# /BIND F1 command trackbar
|
||||||
|
#
|
||||||
|
##
|
||||||
|
|
||||||
|
## Bugfixes and new items in this rewrite.
|
||||||
|
#
|
||||||
|
# * Remove all the trackbars before upgrading.
|
||||||
|
# * New setting trackbar_use_status_window to control the statuswindow trackbar.
|
||||||
|
# * New setting trackbar_print_timestamp to print a timestamp or not.
|
||||||
|
# * New command 'trackbar' to scroll up to the trackbar.
|
||||||
|
# * When resizing your terminal, Irssi will update all the trackbars to the new size.
|
||||||
|
# * When changing trackbar settings, change all the trackbars to the new settings.
|
||||||
|
# * New command 'trackbar mark' to draw a new trackbar (The old '/mark').
|
||||||
|
# * New command 'trackbar markall' to draw a new trackbar in each window.
|
||||||
|
# * New command 'trackbar remove' to remove the trackbar from the current window.
|
||||||
|
# * New command 'trackbar removeall' to remove all the trackbars.
|
||||||
|
# * Don't draw a trackbar in empty windows.
|
||||||
|
# * Added a version check to prevent Irssi redraw errors.
|
||||||
|
# * Fixed a bookmark NULL versus 0 bug.
|
||||||
|
# * Fixed a remove-line bug in Uwe Dudenhoeffer his patch.
|
||||||
|
# * New command 'help trackbar' to display the trackbar commands.
|
||||||
|
# * Fixed an Irssi startup bug, now processing each auto-created window.
|
||||||
|
#
|
||||||
|
##
|
||||||
|
|
||||||
|
## Known bugs and the todolist.
|
||||||
|
#
|
||||||
|
# Todo: * Instead of drawing a line, invert the line.
|
||||||
|
#
|
||||||
|
##
|
||||||
|
|
||||||
|
## Authors:
|
||||||
|
#
|
||||||
|
# - Main maintainer & author: Peter 'kinlo' Leurs
|
||||||
|
# - Many thanks to Timo 'cras' Sirainen for placing me on my way
|
||||||
|
# - on-upgrade-remove-line patch by Uwe Dudenhoeffer
|
||||||
|
# - trackbar resizing by Michiel Holtkamp (02 Jul 2012)
|
||||||
|
# - scroll to trackbar, window excludes, and timestamp options by Nico R.
|
||||||
|
# Wohlgemuth (22 Sep 2012)
|
||||||
|
#
|
||||||
|
##
|
||||||
|
|
||||||
|
## Version history:
|
||||||
|
#
|
||||||
|
# 2.9: - fix crash on /mark in empty window
|
||||||
|
# 2.8: - fix /^join bug
|
||||||
|
# 2.7: - add /set trackbar_all_manual option
|
||||||
|
# 2.5: - merge back on scripts.irssi.org
|
||||||
|
# - fix /trackbar redraw broken in 2.4
|
||||||
|
# - fix legacy encodings
|
||||||
|
# - add workaround for irssi issue #271
|
||||||
|
# 2.4: - add support for horizontal splits
|
||||||
|
# 2.3: - add some features for seen tracking using other scripts
|
||||||
|
# 2.0: - big rewrite based on 1.4
|
||||||
|
# * removed /tb, you can have it with /alias tb trackbar if you want
|
||||||
|
# * subcommand and settings changes:
|
||||||
|
# /trackbar vmark => /trackbar markvisible
|
||||||
|
# /trackbar scroll => /trackbar goto (or just /trackbar)
|
||||||
|
# /trackbar help => /help trackbar
|
||||||
|
# /set trackbar_hide_windows => /set trackbar_ignore_windows
|
||||||
|
# /set trackbar_timestamp => /set trackbar_print_timestamp
|
||||||
|
# * magic line strings were removed, just paste the unicode you want!
|
||||||
|
# * trackbar_timestamp_styled is not currently supported
|
||||||
|
# 1.9: - add version guard
|
||||||
|
# 1.8: - sub draw_bar
|
||||||
|
# 1.7: - Added /tb scroll, trackbar_hide_windows, trackbar_timestamp_timestamp
|
||||||
|
# and trackbar_timestamp_styled
|
||||||
|
# 1.6: - Work around Irssi resize bug, please do /upgrade! (see below)
|
||||||
|
# 1.5: - Resize trackbars in all windows when terminal is resized
|
||||||
|
# 1.4: - Changed our's by my's so the irssi script header is valid
|
||||||
|
# - Removed utf-8 support. In theory, the script should work w/o any
|
||||||
|
# problems for utf-8, just set trackbar_string to a valid utf-8 character
|
||||||
|
# and everything *should* work. However, this script is being plagued by
|
||||||
|
# irssi internal bugs. The function Irssi::settings_get_str does NOT handle
|
||||||
|
# unicode strings properly, hence you will notice problems when setting the bar
|
||||||
|
# to a unicode char. For changing your bar to utf-8 symbols, read the line sub.
|
||||||
|
# 1.3: - Upgrade now removes the trackbars.
|
||||||
|
# - Some code cleanups, other defaults
|
||||||
|
# - /mark sets the line to the bottom
|
||||||
|
# 1.2: - Support for utf-8
|
||||||
|
# - How the bar looks can now be configured with trackbar_string
|
||||||
|
# and trackbar_style
|
||||||
|
# 1.1: - Fixed bug when closing window
|
||||||
|
# 1.0: - Initial release
|
||||||
|
#
|
||||||
|
##
|
||||||
|
|
||||||
|
use Irssi;
|
||||||
|
use Irssi::TextUI;
|
||||||
|
use Encode;
|
||||||
|
|
||||||
|
use POSIX qw(strftime);
|
||||||
|
|
||||||
|
sub cmd_help {
|
||||||
|
my ($args) = @_;
|
||||||
|
if ($args =~ /^trackbar *$/i) {
|
||||||
|
print CLIENTCRAP <<HELP
|
||||||
|
%9Syntax:%9
|
||||||
|
|
||||||
|
TRACKBAR
|
||||||
|
TRACKBAR GOTO
|
||||||
|
TRACKBAR KEEP
|
||||||
|
TRACKBAR MARK
|
||||||
|
TRACKBAR MARKVISIBLE
|
||||||
|
TRACKBAR MARKALL
|
||||||
|
TRACKBAR REMOVE
|
||||||
|
TRACKBAR REMOVEALL
|
||||||
|
TRACKBAR REDRAW
|
||||||
|
|
||||||
|
%9Parameters:%9
|
||||||
|
|
||||||
|
GOTO: Jump to where the trackbar is, to pick up reading
|
||||||
|
KEEP: Keep this window's trackbar where it is the next time
|
||||||
|
you switch windows (then this flag is cleared again)
|
||||||
|
MARK: Remove the old trackbar and mark the bottom of this
|
||||||
|
window with a new trackbar
|
||||||
|
MARKVISIBLE: Like mark for all visible windows
|
||||||
|
MARKALL: Like mark for all windows
|
||||||
|
REMOVE: Remove this window's trackbar
|
||||||
|
REMOVEALL: Remove all windows' trackbars
|
||||||
|
REDRAW: Force redraw of trackbars
|
||||||
|
|
||||||
|
%9Description:%9
|
||||||
|
|
||||||
|
Manage a trackbar. Without arguments, it will scroll up to the trackbar.
|
||||||
|
|
||||||
|
%9Examples:%9
|
||||||
|
|
||||||
|
/TRACKBAR MARK
|
||||||
|
/TRACKBAR REMOVE
|
||||||
|
HELP
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Irssi::theme_register([
|
||||||
|
'trackbar_loaded', '%R>>%n %_Scriptinfo:%_ Loaded $0 version $1 by $2.',
|
||||||
|
'trackbar_wrong_version', '%R>>%n %_Trackbar:%_ Please upgrade your client to 0.8.17 or above if you would like to use this feature of trackbar.',
|
||||||
|
'trackbar_all_removed', '%R>>%n %_Trackbar:%_ All the trackbars have been removed.',
|
||||||
|
'trackbar_not_found', '%R>>%n %_Trackbar:%_ No trackbar found in this window.',
|
||||||
|
]);
|
||||||
|
|
||||||
|
my $old_irssi = Irssi::version < 20140701;
|
||||||
|
sub check_version {
|
||||||
|
if ($old_irssi) {
|
||||||
|
Irssi::printformat(MSGLEVEL_CLIENTCRAP, 'trackbar_wrong_version');
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub is_utf8 {
|
||||||
|
lc Irssi::settings_get_str('term_charset') eq 'utf-8'
|
||||||
|
}
|
||||||
|
|
||||||
|
my (%config, %keep_trackbar, %unseen_trackbar);
|
||||||
|
|
||||||
|
sub remove_one_trackbar {
|
||||||
|
my $win = shift;
|
||||||
|
my $view = shift || $win->view;
|
||||||
|
my $line = $view->get_bookmark('trackbar');
|
||||||
|
if (defined $line) {
|
||||||
|
my $bottom = $view->{bottom};
|
||||||
|
$view->remove_line($line);
|
||||||
|
$win->command('^scrollback end') if $bottom && !$win->view->{bottom};
|
||||||
|
$view->redraw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub add_one_trackbar_pt1 {
|
||||||
|
my $win = shift;
|
||||||
|
my $view = shift || $win->view;
|
||||||
|
|
||||||
|
my $last_cur_line = ($view->{buffer}{cur_line}||+{})->{_irssi};
|
||||||
|
$win->print(line($win->{width}), MSGLEVEL_NEVER);
|
||||||
|
|
||||||
|
my $cur_line = ($win->view->{buffer}{cur_line}||+{})->{_irssi}; # get a fresh buffer
|
||||||
|
|
||||||
|
($last_cur_line//'') ne ($cur_line//'') # printing was successful
|
||||||
|
}
|
||||||
|
|
||||||
|
sub add_one_trackbar_pt2 {
|
||||||
|
my $win = shift;
|
||||||
|
my $view = $win->view;
|
||||||
|
|
||||||
|
$view->set_bookmark_bottom('trackbar');
|
||||||
|
$unseen_trackbar{ $win->{_irssi} } = 1;
|
||||||
|
Irssi::signal_emit("window trackbar added", $win);
|
||||||
|
$view->redraw;
|
||||||
|
}
|
||||||
|
|
||||||
|
sub update_one_trackbar {
|
||||||
|
my $win = shift;
|
||||||
|
my $view = shift || $win->view;
|
||||||
|
my $force = shift;
|
||||||
|
my $ignored = win_ignored($win, $view);
|
||||||
|
my $success;
|
||||||
|
|
||||||
|
$success = add_one_trackbar_pt1($win, $view) ? 1 : 0
|
||||||
|
if $force || !$ignored;
|
||||||
|
|
||||||
|
remove_one_trackbar($win, $view)
|
||||||
|
if ( $success || !defined $success ) && ( $force || !defined $force || !$ignored );
|
||||||
|
|
||||||
|
add_one_trackbar_pt2($win)
|
||||||
|
if $success;
|
||||||
|
}
|
||||||
|
|
||||||
|
sub win_ignored {
|
||||||
|
my $win = shift;
|
||||||
|
my $view = shift || $win->view;
|
||||||
|
return 1 unless $view->{buffer}{lines_count};
|
||||||
|
return 1 if $win->{name} eq '(status)' && !$config{use_status_window};
|
||||||
|
no warnings 'uninitialized';
|
||||||
|
return 1 if grep { $win->{name} eq $_ || $win->{refnum} eq $_
|
||||||
|
|| $win->get_active_name eq $_ } @{ $config{ignore_windows} };
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
sub sig_window_changed {
|
||||||
|
my ($newwindow, $oldwindow) = @_;
|
||||||
|
return unless $oldwindow;
|
||||||
|
redraw_one_trackbar($newwindow) unless $old_irssi;
|
||||||
|
trackbar_update_seen($newwindow);
|
||||||
|
return if delete $keep_trackbar{ $oldwindow->{_irssi} };
|
||||||
|
trackbar_update_seen($oldwindow);
|
||||||
|
return if $config{require_seen} && $unseen_trackbar{ $oldwindow->{_irssi } };
|
||||||
|
return if $config{all_manual};
|
||||||
|
update_one_trackbar($oldwindow, undef, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub trackbar_update_seen {
|
||||||
|
my $win = shift;
|
||||||
|
return unless $win;
|
||||||
|
return unless $unseen_trackbar{ $win->{_irssi} };
|
||||||
|
|
||||||
|
my $view = $win->view;
|
||||||
|
my $line = $view->get_bookmark('trackbar');
|
||||||
|
unless ($line) {
|
||||||
|
delete $unseen_trackbar{ $win->{_irssi} };
|
||||||
|
Irssi::signal_emit("window trackbar seen", $win);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
my $startline = $view->{startline};
|
||||||
|
return unless $startline;
|
||||||
|
|
||||||
|
if ($startline->{info}{time} < $line->{info}{time}
|
||||||
|
|| $startline->{_irssi} == $line->{_irssi}) {
|
||||||
|
delete $unseen_trackbar{ $win->{_irssi} };
|
||||||
|
Irssi::signal_emit("window trackbar seen", $win);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub screen_length;
|
||||||
|
{ local $@;
|
||||||
|
eval { require Text::CharWidth; };
|
||||||
|
unless ($@) {
|
||||||
|
*screen_length = sub { Text::CharWidth::mbswidth($_[0]) };
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
*screen_length = sub {
|
||||||
|
my $temp = shift;
|
||||||
|
Encode::_utf8_on($temp) if is_utf8();
|
||||||
|
length($temp)
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
{ my %strip_table = (
|
||||||
|
(map { $_ => '' } (split //, '04261537' . 'kbgcrmyw' . 'KBGCRMYW' . 'U9_8I:|FnN>#[' . 'pP')),
|
||||||
|
(map { $_ => $_ } (split //, '{}%')),
|
||||||
|
);
|
||||||
|
sub c_length {
|
||||||
|
my $o = Irssi::strip_codes($_[0]);
|
||||||
|
$o =~ s/(%(%|Z.{6}|z.{6}|X..|x..|.))/exists $strip_table{$2} ? $strip_table{$2} :
|
||||||
|
$2 =~ m{x(?:0[a-f]|[1-6][0-9a-z]|7[a-x])|z[0-9a-f]{6}}i ? '' : $1/gex;
|
||||||
|
screen_length($o)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub line {
|
||||||
|
my ($width, $time) = @_;
|
||||||
|
my $string = $config{string};
|
||||||
|
$string = ' ' unless length $string;
|
||||||
|
$time ||= time;
|
||||||
|
|
||||||
|
Encode::_utf8_on($string) if is_utf8();
|
||||||
|
my $length = c_length($string);
|
||||||
|
|
||||||
|
my $format = '';
|
||||||
|
if ($config{print_timestamp}) {
|
||||||
|
$format = $config{timestamp_str};
|
||||||
|
$format =~ y/%/\01/;
|
||||||
|
$format =~ s/\01\01/%/g;
|
||||||
|
$format = strftime($format, localtime $time);
|
||||||
|
$format =~ y/\01/%/;
|
||||||
|
}
|
||||||
|
|
||||||
|
my $times = $width / $length;
|
||||||
|
$times += 1 if $times != int $times;
|
||||||
|
my $style = "$config{style}";
|
||||||
|
Encode::_utf8_on($style) if is_utf8();
|
||||||
|
$format .= $style;
|
||||||
|
$width -= c_length($format);
|
||||||
|
$string x= $times;
|
||||||
|
chop $string while length $string && c_length($string) > $width;
|
||||||
|
return $format . $string;
|
||||||
|
}
|
||||||
|
|
||||||
|
sub remove_all_trackbars {
|
||||||
|
for my $window (Irssi::windows) {
|
||||||
|
next unless ref $window;
|
||||||
|
remove_one_trackbar($window);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub UNLOAD {
|
||||||
|
remove_all_trackbars();
|
||||||
|
}
|
||||||
|
|
||||||
|
sub redraw_one_trackbar {
|
||||||
|
my $win = shift;
|
||||||
|
my $view = $win->view;
|
||||||
|
my $line = $view->get_bookmark('trackbar');
|
||||||
|
return unless $line;
|
||||||
|
my $bottom = $view->{bottom};
|
||||||
|
$win->print_after($line, MSGLEVEL_NEVER, line($win->{width}, $line->{info}{time}),
|
||||||
|
$line->{info}{time});
|
||||||
|
$view->set_bookmark('trackbar', $win->last_line_insert);
|
||||||
|
$view->remove_line($line);
|
||||||
|
$win->command('^scrollback end') if $bottom && !$win->view->{bottom};
|
||||||
|
$view->redraw;
|
||||||
|
}
|
||||||
|
|
||||||
|
sub redraw_trackbars {
|
||||||
|
return unless check_version();
|
||||||
|
for my $win (Irssi::windows) {
|
||||||
|
next unless ref $win;
|
||||||
|
redraw_one_trackbar($win);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub goto_trackbar {
|
||||||
|
my $win = Irssi::active_win;
|
||||||
|
my $line = $win->view->get_bookmark('trackbar');
|
||||||
|
|
||||||
|
if ($line) {
|
||||||
|
$win->command("scrollback goto ". strftime("%d %H:%M:%S", localtime($line->{info}{time})));
|
||||||
|
} else {
|
||||||
|
$win->printformat(MSGLEVEL_CLIENTCRAP, 'trackbar_not_found');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub cmd_mark {
|
||||||
|
update_one_trackbar(Irssi::active_win, undef, 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub cmd_markall {
|
||||||
|
for my $window (Irssi::windows) {
|
||||||
|
next unless ref $window;
|
||||||
|
update_one_trackbar($window);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub signal_stop {
|
||||||
|
Irssi::signal_stop;
|
||||||
|
}
|
||||||
|
|
||||||
|
sub cmd_markvisible {
|
||||||
|
my @wins = Irssi::windows;
|
||||||
|
my $awin =
|
||||||
|
my $bwin = Irssi::active_win;
|
||||||
|
my $awin_counter = 0;
|
||||||
|
Irssi::signal_add_priority('window changed' => 'signal_stop', -99);
|
||||||
|
do {
|
||||||
|
Irssi::active_win->command('window up');
|
||||||
|
$awin = Irssi::active_win;
|
||||||
|
update_one_trackbar($awin);
|
||||||
|
++$awin_counter;
|
||||||
|
} until ($awin->{refnum} == $bwin->{refnum} || $awin_counter >= @wins);
|
||||||
|
Irssi::signal_remove('window changed' => 'signal_stop');
|
||||||
|
}
|
||||||
|
|
||||||
|
sub cmd_trackbar_remove_one {
|
||||||
|
remove_one_trackbar(Irssi::active_win);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub cmd_remove_all_trackbars {
|
||||||
|
remove_all_trackbars();
|
||||||
|
Irssi::printformat(MSGLEVEL_CLIENTCRAP, 'trackbar_all_removed');
|
||||||
|
}
|
||||||
|
|
||||||
|
sub cmd_keep_once {
|
||||||
|
$keep_trackbar{ Irssi::active_win->{_irssi} } = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
sub trackbar_runsub {
|
||||||
|
my ($data, $server, $item) = @_;
|
||||||
|
$data =~ s/\s+$//g;
|
||||||
|
|
||||||
|
if ($data) {
|
||||||
|
Irssi::command_runsub('trackbar', $data, $server, $item);
|
||||||
|
} else {
|
||||||
|
goto_trackbar();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub update_config {
|
||||||
|
my $was_status_window = $config{use_status_window};
|
||||||
|
$config{style} = Irssi::settings_get_str('trackbar_style');
|
||||||
|
$config{string} = Irssi::settings_get_str('trackbar_string');
|
||||||
|
$config{require_seen} = Irssi::settings_get_bool('trackbar_require_seen');
|
||||||
|
$config{all_manual} = Irssi::settings_get_bool('trackbar_all_manual');
|
||||||
|
$config{ignore_windows} = [ split /[,\s]+/, Irssi::settings_get_str('trackbar_ignore_windows') ];
|
||||||
|
$config{use_status_window} = Irssi::settings_get_bool('trackbar_use_status_window');
|
||||||
|
$config{print_timestamp} = Irssi::settings_get_bool('trackbar_print_timestamp');
|
||||||
|
if (defined $was_status_window && $was_status_window != $config{use_status_window}) {
|
||||||
|
if (my $swin = Irssi::window_find_name('(status)')) {
|
||||||
|
if ($config{use_status_window}) {
|
||||||
|
update_one_trackbar($swin);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
remove_one_trackbar($swin);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ($config{print_timestamp}) {
|
||||||
|
my $ts_format = Irssi::settings_get_str('timestamp_format');
|
||||||
|
my $ts_theme = Irssi::current_theme->get_format('fe-common/core', 'timestamp');
|
||||||
|
my $render_str = Irssi::current_theme->format_expand($ts_theme);
|
||||||
|
(my $ts_escaped = $ts_format) =~ s/([%\$])/$1$1/g;
|
||||||
|
$render_str =~ s/(?|\$(.)(?!\w)|\$\{(\w+)\})/$1 eq 'Z' ? $ts_escaped : $1/ge;
|
||||||
|
$config{timestamp_str} = $render_str;
|
||||||
|
}
|
||||||
|
redraw_trackbars() unless $old_irssi;
|
||||||
|
}
|
||||||
|
|
||||||
|
Irssi::settings_add_str('trackbar', 'trackbar_string', is_utf8() ? "\x{2500}" : '-');
|
||||||
|
Irssi::settings_add_str('trackbar', 'trackbar_style', '%K');
|
||||||
|
Irssi::settings_add_str('trackbar', 'trackbar_ignore_windows', '');
|
||||||
|
Irssi::settings_add_bool('trackbar', 'trackbar_use_status_window', 1);
|
||||||
|
Irssi::settings_add_bool('trackbar', 'trackbar_print_timestamp', 0);
|
||||||
|
Irssi::settings_add_bool('trackbar', 'trackbar_require_seen', 0);
|
||||||
|
Irssi::settings_add_bool('trackbar', 'trackbar_all_manual', 0);
|
||||||
|
|
||||||
|
update_config();
|
||||||
|
|
||||||
|
Irssi::signal_add_last( 'mainwindow resized' => 'redraw_trackbars')
|
||||||
|
unless $old_irssi;
|
||||||
|
|
||||||
|
Irssi::signal_register({'window trackbar added' => [qw/Irssi::UI::Window/]});
|
||||||
|
Irssi::signal_register({'window trackbar seen' => [qw/Irssi::UI::Window/]});
|
||||||
|
Irssi::signal_register({'gui page scrolled' => [qw/Irssi::UI::Window/]});
|
||||||
|
Irssi::signal_add_last('gui page scrolled' => 'trackbar_update_seen');
|
||||||
|
|
||||||
|
Irssi::signal_add('setup changed' => 'update_config');
|
||||||
|
Irssi::signal_add_priority('session save' => 'remove_all_trackbars', Irssi::SIGNAL_PRIORITY_HIGH-1);
|
||||||
|
|
||||||
|
Irssi::signal_add('window changed' => 'sig_window_changed');
|
||||||
|
|
||||||
|
Irssi::command_bind('trackbar goto' => 'goto_trackbar');
|
||||||
|
Irssi::command_bind('trackbar keep' => 'cmd_keep_once');
|
||||||
|
Irssi::command_bind('trackbar mark' => 'cmd_mark');
|
||||||
|
Irssi::command_bind('trackbar markvisible' => 'cmd_markvisible');
|
||||||
|
Irssi::command_bind('trackbar markall' => 'cmd_markall');
|
||||||
|
Irssi::command_bind('trackbar remove' => 'cmd_trackbar_remove_one');
|
||||||
|
Irssi::command_bind('trackbar removeall' => 'cmd_remove_all_trackbars');
|
||||||
|
Irssi::command_bind('trackbar redraw' => 'redraw_trackbars');
|
||||||
|
Irssi::command_bind('trackbar' => 'trackbar_runsub');
|
||||||
|
Irssi::command_bind('mark' => 'cmd_mark');
|
||||||
|
Irssi::command_bind_last('help' => 'cmd_help');
|
||||||
|
|
||||||
|
Irssi::printformat(MSGLEVEL_CLIENTCRAP, 'trackbar_loaded', $IRSSI{name}, $VERSION, $IRSSI{authors});
|
||||||
|
|
||||||
|
# workaround for issue #271
|
||||||
|
{ package Irssi::Nick }
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user