-
Notifications
You must be signed in to change notification settings - Fork 38
/
BlaCk-Void.ztheme
702 lines (629 loc) ยท 30.6 KB
/
BlaCk-Void.ztheme
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
# Unused vars don't check
# shellcheck disable=SC2034
## == Powerlevel10k Set ========================================================
## -- Theme Mode ---------------------------------------------------------------
# Theme Mode: auto powerline simple powerline-single simple-single | TODO: normal normal-single
export BVZSH_THEME="${BVZSH_THEME:=auto}"
# Color Mode: auto fixed flex
export BVZSH_COLOR="${BVZSH_COLOR:=auto}"
# TODO: Icon Mode: auto nerd powerline | TODO: emoji unicode ascii
export BVZSH_ICON="${BVZSH_ICON:=auto}"
## -- Color Set ----------------------------------------------------------------
## Color
# for code ({000..255}) print -P -- "$code: %F{$code}This is how your text would look like%f"
# getColorCode background
# getColorCode foreground
# Setting => POWERLEVEL9K_{ELEMENT}_FOREGROUND POWERLEVEL9K_{ELEMENT}_BACKGROUND
_color-flex()
{
## -- Original Color code based ----------------------------
black='000'
red='001'
green='002'
yellow='011' # original: 003
blue='004'
magenta='005'
cyan='006'
white='007'
## -- Custom Color code based ------------------------------
orange='003'
grey='008'
light_grey='008'
}
_color-fixed()
{
## -- Original Color code based ----------------------------
black='000'
red='160'
green='040'
yellow='226'
blue='039'
magenta='165' # or '171'
cyan='036'
white='007'
## -- Custom Color code based ------------------------------
orange='208'
grey='244'
light_grey='247'
}
_zsh-color $BVZSH_COLOR
_powerline-color()
{
## -- Left Indicators---------------------------------------
typeset -g POWERLEVEL9K_ROOT_INDICATOR_BACKGROUND=$yellow
typeset -g POWERLEVEL9K_ROOT_INDICATOR_FOREGROUND=$black
typeset -g POWERLEVEL9K_DIR_DEFAULT_BACKGROUND=$blue
typeset -g POWERLEVEL9K_DIR_DEFAULT_FOREGROUND=$black
typeset -g POWERLEVEL9K_DIR_HOME_BACKGROUND=$blue
typeset -g POWERLEVEL9K_DIR_HOME_FOREGROUND=$black
typeset -g POWERLEVEL9K_DIR_HOME_SUBFOLDER_BACKGROUND=$blue
typeset -g POWERLEVEL9K_DIR_HOME_SUBFOLDER_FOREGROUND=$black
typeset -g POWERLEVEL9K_DIR_WRITABLE_FORBIDDEN_BACKGROUND=$red
typeset -g POWERLEVEL9K_DIR_WRITABLE_FORBIDDEN_FOREGROUND=$yellow
typeset -g POWERLEVEL9K_VCS_CLEAN_FOREGROUND=$black
typeset -g POWERLEVEL9K_VCS_CLEAN_BACKGROUND=$green
typeset -g POWERLEVEL9K_VCS_UNTRACKED_FOREGROUND=$black
typeset -g POWERLEVEL9K_VCS_UNTRACKED_BACKGROUND=$green
typeset -g POWERLEVEL9K_VCS_MODIFIED_FOREGROUND=$black
typeset -g POWERLEVEL9K_VCS_MODIFIED_BACKGROUND=$orange
typeset -g POWERLEVEL9K_VI_MODE_INSERT_FOREGROUND=$green
typeset -g POWERLEVEL9K_VI_MODE_INSERT_BACKGROUND=$black
typeset -g POWERLEVEL9K_VI_MODE_NORMAL_FOREGROUND=$orange
typeset -g POWERLEVEL9K_VI_MODE_NORMAL_BACKGROUND=$black
## -- Right Indicators -------------------------------------
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_BACKGROUND=$yellow
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_FOREGROUND=$black
typeset -g POWERLEVEL9K_STATUS_OK_BACKGROUND=$black
typeset -g POWERLEVEL9K_STATUS_OK_FOREGROUND=$green
typeset -g POWERLEVEL9K_STATUS_ERROR_BACKGROUND=$red
typeset -g POWERLEVEL9K_STATUS_ERROR_FOREGROUND=$yellow
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_BACKGROUND=$red
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_FOREGROUND=$yellow
typeset -g POWERLEVEL9K_HISTORY_BACKGROUND=$grey
typeset -g POWERLEVEL9K_HISTORY_FOREGROUND=$black
typeset -g POWERLEVEL9K_LOAD_CRITICAL_BACKGROUND=$red
typeset -g POWERLEVEL9K_LOAD_CRITICAL_FOREGROUND=$yellow
typeset -g POWERLEVEL9K_LOAD_WARNING_BACKGROUND=$yellow
typeset -g POWERLEVEL9K_LOAD_WARNING_FOREGROUND=$black
typeset -g POWERLEVEL9K_LOAD_NORMAL_BACKGROUND=$green
typeset -g POWERLEVEL9K_LOAD_NORMAL_FOREGROUND=$black
}
_simple-color()
{
## -- Left Indicators---------------------------------------
typeset -g POWERLEVEL9K_CONTEXT_{DEFAULT,ROOT,SUDO,REMOTE,REMOTE_SUDO}_BACKGROUND=$black
typeset -g POWERLEVEL9K_CONTEXT_{DEFAULT,ROOT,SUDO,REMOTE,REMOTE_SUDO}_FOREGROUND=$light_grey
typeset -g POWERLEVEL9K_DIR_DEFAULT_BACKGROUND=$black
typeset -g POWERLEVEL9K_DIR_DEFAULT_FOREGROUND=$blue
typeset -g POWERLEVEL9K_DIR_HOME_BACKGROUND=$black
typeset -g POWERLEVEL9K_DIR_HOME_FOREGROUND=$blue
typeset -g POWERLEVEL9K_DIR_HOME_SUBFOLDER_BACKGROUND=$black
typeset -g POWERLEVEL9K_DIR_HOME_SUBFOLDER_FOREGROUND=$blue
typeset -g POWERLEVEL9K_VCS_CLEAN_FOREGROUND=$light_grey #or $green or $magenta
typeset -g POWERLEVEL9K_VCS_CLEAN_BACKGROUND=$black
typeset -g POWERLEVEL9K_VCS_UNTRACKED_FOREGROUND=$light_grey
typeset -g POWERLEVEL9K_VCS_UNTRACKED_BACKGROUND=$black
typeset -g POWERLEVEL9K_VCS_MODIFIED_FOREGROUND=$orange
typeset -g POWERLEVEL9K_VCS_MODIFIED_BACKGROUND=$black
typeset -g POWERLEVEL9K_VCS_{CLEAN,UNTRACKED}_UNTRACKEDFORMAT_FOREGROUND=$POWERLEVEL9K_VCS_UNTRACKED_FOREGROUND
typeset -g POWERLEVEL9K_VCS_MODIFIED_UNTRACKEDFORMAT_FOREGROUND=$POWERLEVEL9K_VCS_MODIFIED_FOREGROUND
typeset -g POWERLEVEL9K_VCS_{CLEAN,UNTRACKED,MODIFIED}_UNSTAGEDFORMAT_FOREGROUND=$POWERLEVEL9K_VCS_MODIFIED_FOREGROUND
typeset -g POWERLEVEL9K_VCS_{CLEAN,UNTRACKED,MODIFIED}_STAGEDFORMAT_FOREGROUND=$POWERLEVEL9K_VCS_MODIFIED_FOREGROUND
typeset -g POWERLEVEL9K_VCS_{CLEAN,UNTRACKED,MODIFIED}_INCOMING_CHANGESFORMAT_FOREGROUND=$cyan
typeset -g POWERLEVEL9K_VCS_{CLEAN,UNTRACKED,MODIFIED}_OUTGOING_CHANGESFORMAT_FOREGROUND=$cyan
typeset -g POWERLEVEL9K_VCS_{CLEAN,UNTRACKED,MODIFIED}_STASHFORMAT_FOREGROUND=$cyan
typeset -g POWERLEVEL9K_VCS_{CLEAN,UNTRACKED,MODIFIED}_ACTIONFORMAT_FOREGROUND=$red
typeset -g POWERLEVEL9K_DIR_WRITABLE_FORBIDDEN_BACKGROUND=$black
typeset -g POWERLEVEL9K_DIR_WRITABLE_FORBIDDEN_FOREGROUND=$yellow
typeset -g POWERLEVEL9K_DIR_WRITABLE_FORBIDDEN_BACKGROUND=$black
typeset -g POWERLEVEL9K_DIR_WRITABLE_FORBIDDEN_VISUAL_IDENTIFIER_COLOR=$yellow
typeset -g POWERLEVEL9K_ROOT_INDICATOR_BACKGROUND=$black
typeset -g POWERLEVEL9K_ROOT_INDICATOR_FOREGROUND=$yellow
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_BACKGROUND=$black
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_FOREGROUND=$orange
## -- Right Indicators -------------------------------------
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_BACKGROUND=$black
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_FOREGROUND=$light_grey
typeset -g POWERLEVEL9K_STATUS_ERROR_BACKGROUND=$black
typeset -g POWERLEVEL9K_STATUS_ERROR_FOREGROUND=$light_grey
}
## -- Icon Set -----------------------------------------------------------------
## Icons
# get_icon_names => show icons.
# Setting => POWERLEVEL9K_{ICONNAME}_ICON
_icon-powerline()
{
background_jobs=$'\u3002' # ใ
carriage_return=$'\u21B5' # โต
execution_time="Due"
fail=$'\u2718' # โ
kubernetes=$'\u2388' # โ
load='L'
lock=$'\uE0A2' # ๎ข
ok=$'\u2714' # โ
root="\u26A1 root" # โก or #
ssh="(ssh)"
vcs_bookmark=$'\u263F' # โฟ
vcs_branch=$'\uE0A0' # ๎
vcs_commit='\u27A6' # โฆ or '-O-' or '@'
vcs_incoming_changes=$'\u21E3' # โฃ or '\u2193' โ
vcs_outgoing_changes=$'\u21E1' # โก or '\u2191' โ
vcs_remote_branch=$'\u21DD' # โ or '\u2192' โ
vcs_staged=$'\uFF0B' # ๏ผ or '\u2795' โ or '+'
vcs_stash=$'\uFF0A' # ๏ผ or '*'
vcs_unstaged=$'\u25CF' # โ or '\uFF01' ๏ผ or '!' or '\u00B1' ยฑ or '+-'
vcs_untracked=$'\uFF1F' # ๏ผ or '\u2753' โ or '?'
vpn="(vpn)"
}
_icon-nerd()
{
android=$'\uF17B ' # ๏
ป or '\uE70E' ๎
apple=$'\uF179 ' # ๏
น
aws=$'\uF1B3 ' # ๏ณ or '\uF270 ' ๏ฐ
aws_eb=$'\uF1BD ' # ๏ฝ or '\uE7AD' ๎ญ
background_jobs=$'\uF013 ' # ๏ or '\u3002' ใ
battery=$'\uF241 ' # ๏ or '\uF240 ' ๏
carriage_return=$'\u21B5' # โต
date=$'\uF073 ' # ๏ณ
disk=$'\uF0A0 ' # ๏
dropbox=$'\UF16B' # ๏
ซ
etc='' # or '\uF013' ๏
execution_time="Due" # or '\uF252 ' ๏
fail=$'\u2718' # โ or '\uF00D' ๏
folder='' # or '\uF07B ' ๏ป or '\uF115' ๏
freebsd=$'\uF30C ' # ๏
go=$'\uE724' #๎ค or '\uE626' ๎ฆ
home= # or '\uF015' ๏
home_sub= # or '\uF07C' ๏ผ
java=$'\u2615' # โ๏ธ
kubernetes=$'\u2388' # โ
laravel=$'\uE73F ' # ๎ฟ
linux=$'\uF17C ' # ๏
ผ
linux_alpine=$'\uF300' # ๏
linux_aosc=$'\uF301' # ๏
linux_arch=$'\uF303' # ๏
linux_centos=$'\uF304' # ๏
linux_coreos=$'\uF305' # ๏
linux_debian=$'\uF306' # ๏
linux_devuan=$'\uF307' # ๏
linux_elementary=$'\uF309' # ๏
linux_fedora=$'\uF30A' # ๏
linux_gentoo=$'\uF30D' # ๏
linux_mageia=$'\uF310' # ๏
linux_manjaro=$'\uF312' # ๏
linux_mint=$'\uF30E' # ๏
linux_nixos=$'\uF313' # ๏
linux_opensuse=$'\uF314' # ๏
linux_sabayon=$'\uF317' # ๏
linux_slackware=$'\uF319' # ๏
linux_ubuntu=$'\uF31B' # ๏
load=$'\uF524' # ๏ค or 'L' or $'\uF140 ' ๏
or '\uF080 ' ๏
lock=$'\uF023' # ๏ฃ or '\uE0A2' ๎ข
network=$'\uF012 ' # ๏ or $'\uF1FE ' ๏พ or '\uF1EB' ๏ซ
node='\uE617 ' # ๎ or'\uE24F' โฌข
ok=$'\u2714' # โ or $'\uF00C ' ๏
public_ip=$'\uF080 ' # ๏ or $'\uF469' ๏ฉ or '\uF0AC' ๏ฌ
python=$'\uF81F' # ๏ or '\uE73C ' # ๎ผ
ram=$'\uF2DB ' # ๏ or $'\uF0E4 ' ๏ค
root="\uF0E7 root" # ๏ง or '\u26A1' or '\uF09C' ๏ or '\uF292' ๏ or '\uE614 ' ๎ or '#'
ruby=$'\uF219 ' # ๏ or '\uE791' ๎ or $'\uE739' ๎น
rust=$'\uE7A8' # ๎จ
server=$'\uF233 ' # ๏ณ or '\uF473' ๏ณ or '\uF0AE ' ๏ฎ
ssh="(ssh)" # or '\uF120' ๏ or '\uE795' ๎ or '\uF489' # ๏
sudo=$'\uF09C' # ๏
sunos=$'\uF185 ' # ๏
swap=$'\uF464' # ๏ค or '\uF0C7 ' ๏ or '\uF109 ' ๏
swift=$'\uE755' # ๎
symfony=$'\uE757' # ๎
test=$'\uE29A ' # ๏ or '\uF188' ๏
time=$'\uF017 ' # ๏
todo=$'\uF046 ' # ๏ or '\uF133' ๏ณ
vcs_bookmark=$'\uF461 ' # ๏ก or '\uF02E' ๏ฎ or '\uF097' ๏ or '\uF08D' ๏ or $'\uF223' ๏ฃ or '\u263F' โฟ
vcs_branch=$'\uF126 ' # ๏ฆ or '\uE702' ๎ or '\uE0A0' ๎
vcs_commit='\uE729' # ๎ฉ or "-o-" or '\u27A6' โฆ or '@'
vcs_git=$'\uF1D3 ' # ๏ or '\uF1D2' ๏
vcs_git_bitbucket=$'\uF171 ' # ๏
ฑ or '\uF172 ' ๏
ฒ or '\uE703' ๎
vcs_git_github=$'\uF113 ' # ๏ or '\uF09B ' ๏ or '\uF092 ' ๏
vcs_git_gitlab=$'\uF296 ' # ๏
vcs_hg=$'\uF223 ' # ๏ฃ or ๏
vcs_incoming_changes=$'\uF063' # ๏ฃ or '\uF01A' ๏ or '\uF0AB' ๏ซ or '\uD727' ๎ง or '\u21E3' โฃ or '\u2193' โ
vcs_outgoing_changes=$'\uF062' # ๏ข or '\uF01B' ๏ or '\uF0AA' ๏ช or '\uE726' ๎ฆ or '\u21E1' โก or '\u2191' โ
vcs_remote_branch=$'\uF061 ' # ๏ก or '\uF18E' ๏ or '\uF0A9' ๏ฉ or '\uE725' ๎ฅ or '\u21DD' โ or '\u2192' โ or '\uE728 ' ๎จ
vcs_staged=$'\uF067' # โ or '\uF055' ๏ or '\uF0FE' ๏พ or '\uF067' โ or '\uFF0B' ๏ผ or '\u2795' โ or '+'
vcs_stash=$'\uF01C' # ๏ or '\uF192' ๏ or '\u235F' โ or '\uFF0A' ๏ผ or '*'
vcs_svn=$'\uE72D ' # ๎ญ or'\uE268' ๎จ
vcs_tag=$'\uF02C ' # ๏ฌ or '\uF02B ' ๏ซ
vcs_unstaged=$'\u25CF' # โ or '\uF111' ๏ or '\uF06A' ๏ช or '\uF12A' ๏ช or '\uF071' ๏ฑ or '\uFF01' ๏ผ or '!' or '\u00B1' ยฑ or '+-'
vcs_untracked=$'\uF128' # ๏จ or '\uF059' ๏ '\uF29C' ๏ or '\uFF1F' ๏ผ or '\u2753' โ or '?'
vpn="(vpn)"
windows=$'\uF17A ' # ๏
บ or '\uF17A' ๎
}
_zsh-icon $BVZSH_ICON
_powerline-icon()
{
typeset -g POWERLEVEL9K_ANDROID_ICON=$android
typeset -g POWERLEVEL9K_APPLE_ICON=$apple
typeset -g POWERLEVEL9K_AWS_ICON=$aws
typeset -g POWERLEVEL9K_AWS_EB_ICON=$aws_eb
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_ICON=$background_jobs
typeset -g POWERLEVEL9K_BATTERY_ICON=$battery
typeset -g POWERLEVEL9K_CARRIAGE_RETURN_ICON=$carriage_return
typeset -g POWERLEVEL9K_DATE_ICON=$date
typeset -g POWERLEVEL9K_DISK_ICON=$disk
typeset -g POWERLEVEL9K_DROPBOX_ICON=$dropbox
typeset -g POWERLEVEL9K_ETC_ICON=$etc
typeset -g POWERLEVEL9K_EXECUTION_TIME_ICON=$execution_time
typeset -g POWERLEVEL9K_FAIL_ICON=$fail
typeset -g POWERLEVEL9K_FOLDER_ICON=$folder
typeset -g POWERLEVEL9K_FREEBSD_ICON=$freebsd
typeset -g POWERLEVEL9K_GO_ICON=$go
typeset -g POWERLEVEL9K_HOME_ICON=$home
typeset -g POWERLEVEL9K_HOME_SUB_ICON=$home_sub
typeset -g POWERLEVEL9K_JAVA_ICON=$java
typeset -g POWERLEVEL9K_KUBERNETES_ICON=$kubernetes
typeset -g POWERLEVEL9K_LARAVEL_ICON=$laravel
typeset -g POWERLEVEL9K_LINUX_ICON=$linux
typeset -g POWERLEVEL9K_LINUX_ALPINE_ICON=$linux_alpine
typeset -g POWERLEVEL9K_LINUX_AOSC_ICON=$linux_aosc
typeset -g POWERLEVEL9K_LINUX_ARCH_ICON=$linux_arch
typeset -g POWERLEVEL9K_LINUX_CENTOS_ICON=$linux_centos
typeset -g POWERLEVEL9K_LINUX_COREOS_ICON=$linux_coreos
typeset -g POWERLEVEL9K_LINUX_DEBIAN_ICON=$linux_debian
typeset -g POWERLEVEL9K_LINUX_DEVUAN_ICON=$linux_devuan
typeset -g POWERLEVEL9K_LINUX_ELEMENTARY_ICON=$linux_elementary
typeset -g POWERLEVEL9K_LINUX_FEDORA_ICON=$linux_fedora
typeset -g POWERLEVEL9K_LINUX_GENTOO_ICON=$linux_gentoo
typeset -g POWERLEVEL9K_LINUX_MAGEIA_ICON=$linux_mageia
typeset -g POWERLEVEL9K_LINUX_MANJARO_ICON=$linux_manjaro
typeset -g POWERLEVEL9K_LINUX_MINT_ICON=$linux_mint
typeset -g POWERLEVEL9K_LINUX_NIXOS_ICON=$linux_nixos
typeset -g POWERLEVEL9K_LINUX_OPENSUSE_ICON=$linux_opensuse
typeset -g POWERLEVEL9K_LINUX_SABAYON_ICON=$linux_sabayon
typeset -g POWERLEVEL9K_LINUX_SLACKWARE_ICON=$linux_slackware
typeset -g POWERLEVEL9K_LINUX_UBUNTU_ICON=$linux_ubuntu
typeset -g POWERLEVEL9K_LOAD_ICON=$load
typeset -g POWERLEVEL9K_LOCK_ICON=$lock
typeset -g POWERLEVEL9K_NETWORK_ICON=$network
typeset -g POWERLEVEL9K_NODE_ICON=$node
typeset -g POWERLEVEL9K_OK_ICON=$ok
typeset -g POWERLEVEL9K_PUBLIC_IP_ICON=$public_ip
typeset -g POWERLEVEL9K_PYTHON_ICON=$python
typeset -g POWERLEVEL9K_RAM_ICON=$ram
typeset -g POWERLEVEL9K_ROOT_ICON=$root
typeset -g POWERLEVEL9K_RUBY_ICON=$ruby
typeset -g POWERLEVEL9K_RUST_ICON=$rust
typeset -g POWERLEVEL9K_SERVER_ICON=$server
typeset -g POWERLEVEL9K_SSH_ICON=$ssh
typeset -g POWERLEVEL9K_SUDO_ICON=$sudo
typeset -g POWERLEVEL9K_SUNOS_ICON=$sunos
typeset -g POWERLEVEL9K_SWAP_ICON=$swap
typeset -g POWERLEVEL9K_SWIFT_ICON=$swift
typeset -g POWERLEVEL9K_SYMFONY_ICON=$symfony
typeset -g POWERLEVEL9K_TEST_ICON=$test
typeset -g POWERLEVEL9K_TIME_ICON=$time
typeset -g POWERLEVEL9K_TODO_ICON=$todo
typeset -g POWERLEVEL9K_VCS_BOOKMARK_ICON=$vcs_bookmark
typeset -g POWERLEVEL9K_VCS_BRANCH_ICON=$vcs_branch
typeset -g POWERLEVEL9K_VCS_COMMIT_ICON=$vcs_commit
typeset -g POWERLEVEL9K_VCS_GIT_ICON=$vcs_git
typeset -g POWERLEVEL9K_VCS_GIT_BITBUCKET_ICON=$vcs_git_bitbucket
typeset -g POWERLEVEL9K_VCS_GIT_GITHUB_ICON=$vcs_git_github
typeset -g POWERLEVEL9K_VCS_GIT_GITLAB_ICON=$vcs_git_gitlab
typeset -g POWERLEVEL9K_VCS_HG_ICON=$vcs_hg
typeset -g POWERLEVEL9K_VCS_INCOMING_CHANGES_ICON=$vcs_incoming_changes
typeset -g POWERLEVEL9K_VCS_OUTGOING_CHANGES_ICON=$vcs_outgoing_changes
typeset -g POWERLEVEL9K_VCS_REMOTE_BRANCH_ICON=$vcs_remote_branch
typeset -g POWERLEVEL9K_VCS_STAGED_ICON=$vcs_staged
typeset -g POWERLEVEL9K_VCS_STASH_ICON=$vcs_stash
typeset -g POWERLEVEL9K_VCS_SVN_ICON=$vcs_svn
typeset -g POWERLEVEL9K_VCS_TAG_ICON=$vcs_tag
typeset -g POWERLEVEL9K_VCS_UNSTAGED_ICON=$vcs_unstaged
typeset -g POWERLEVEL9K_VCS_UNTRACKED_ICON=$vcs_untracked
typeset -g POWERLEVEL9K_VPN_ICON=$vpn
typeset -g POWERLEVEL9K_WINDOWS_ICON=$windows
}
_simple-icon()
{
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_ICON=$background_jobs
typeset -g POWERLEVEL9K_CARRIAGE_RETURN_ICON=$carriage_return
typeset -g POWERLEVEL9K_EXECUTION_TIME_ICON=$execution_time
typeset -g POWERLEVEL9K_LOCK_ICON=$lock
typeset -g POWERLEVEL9K_ROOT_ICON=$root
typeset -g POWERLEVEL9K_VCS_BOOKMARK_ICON=$vcs_bookmark
typeset -g POWERLEVEL9K_VCS_BRANCH_ICON=$vcs_branch
typeset -g POWERLEVEL9K_VCS_COMMIT_ICON=$vcs_commit
typeset -g POWERLEVEL9K_VCS_GIT_ICON=$vcs_git
typeset -g POWERLEVEL9K_VCS_GIT_BITBUCKET_ICON=$vcs_git_bitbucket
typeset -g POWERLEVEL9K_VCS_GIT_GITHUB_ICON=$vcs_git_github
typeset -g POWERLEVEL9K_VCS_GIT_GITLAB_ICON=$vcs_git_gitlab
typeset -g POWERLEVEL9K_VCS_HG_ICON=$vcs_hg
typeset -g POWERLEVEL9K_VCS_INCOMING_CHANGES_ICON=$vcs_incoming_changes
typeset -g POWERLEVEL9K_VCS_OUTGOING_CHANGES_ICON=$vcs_outgoing_changes
typeset -g POWERLEVEL9K_VCS_REMOTE_BRANCH_ICON=$vcs_remote_branch
typeset -g POWERLEVEL9K_VCS_STAGED_ICON=$vcs_staged
typeset -g POWERLEVEL9K_VCS_STASH_ICON=$vcs_tag
typeset -g POWERLEVEL9K_VCS_SVN_ICON=$vcs_svn
typeset -g POWERLEVEL9K_VCS_TAG_ICON=$vcs_tag
typeset -g POWERLEVEL9K_VCS_UNSTAGED_ICON=$vcs_unstaged
typeset -g POWERLEVEL9K_VCS_UNTRACKED_ICON=$vcs_untracked
}
## -- Theme Set ----------------------------------------------------------------
## Prompt Elements
# POWERLEVEL9K_LEFT_PROMPT_ELEMENTS POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS
# POWERLEVEL9K_PROMPT_ON_NEWLINE POWERLEVEL9K_PROMPT_ADD_NEWLINE POWERLEVEL9K_RPROMPT_ON_NEWLINE
## System Status Segments
# background_jobs battery context dir dir_writable disk_usage history
# host ip vpn_ip public_ip load os_icon ram root_indicator status swap
# time user vi_mode ssh
## Development Environment Segments
# vcs
## Language Segments
# GO => go_version
# Javascript => node_version nodeenv nvm
# PHP => php_version symfony2tests symfony2_version
# Python => virtualenv anaconda pyenv
# Ruby => chruby rbenv rspec_stats rvm
# Rust => rust_version
# Swift => swift_version
## Cloud Segments
# AWS => aws aws_en_env
# Other => docker_machine kubecontext
## Other Segments
# custom_commmand command_execution_time todo detect_virt newline
## Zsh Segments codes.
# %F => color dict
# %f => reset color
# %~ => current path
# %* => time
# %n => username
# %m => shortname host
# %(?..) => prompt conditional - %(condition.true.false)
## Terminal codes
# \e7 => save cursor position
# \e[2A => move cursor 2 lines up
# \e[1G => go to position 1 in terminal
# \e8 => restore cursor position
# \e[K => clears everything after the cursor on the current line
# \e[2K => clear everything on the current line
## ETC Prompt Expansion
# http://zsh.sourceforge.net/Doc/Release/Prompt-Expansion.html
ENV_PROMPT_ELEMENTS=(direnv virtualenv anaconda pyenv goenv nodenv nvm nodeenv
rbenv rvm fvm lauaenv jenv plenv kubecontext terrafrom
aws aws_eb_env azure gcloud google_app_cred)
_powerline-nerd()
{
## -- Prompts Set ------------------------------------------
## Prompt
typeset -ga POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(ssh context root_indicator dir dir_writable vcs)
typeset -ga POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(status background_jobs command_execution_time
"${ENV_PROMPT_ELEMENTS[@]}" history load)
## Double-Lined Prompt
typeset -g POWERLEVEL9K_PROMPT_ON_NEWLINE=true
typeset -g POWERLEVEL9K_PROMPT_ADD_NEWLINE=true
typeset -g POWERLEVEL9K_RPROMPT_ON_NEWLINE=false
## Other Prompt
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_VERBOSE=true
typeset -g POWERLEVEL9K_STATUS_OK=true
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_THRESHOLD=0
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_PRECISION=2
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR='ยท' # '-' or 'โ'
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_BACKGROUND=
if [[ $POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR != ' ' ]]; then
# The color of the filler. You'll probably want to match the color of POWERLEVEL9K_MULTILINE
# ornaments defined above.
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_FOREGROUND=240
# Start filler from the edge of the screen if there are no left segments on the first line.
typeset -g POWERLEVEL9K_EMPTY_LINE_LEFT_PROMPT_FIRST_SEGMENT_END_SYMBOL='%{%}'
# End filler on the edge of the screen if there are no right segments on the first line.
typeset -g POWERLEVEL9K_EMPTY_LINE_RIGHT_PROMPT_FIRST_SEGMENT_START_SYMBOL='%{%}'
fi
#typeset -g POWERLEVEL9K_CHANGESET_HASH_LENGTH=6
#typeset -g POWERLEVEL9K_SHORTEN_STRATEGY="truncate_middle"
typeset -g POWERLEVEL9K_SHORTEN_DIR_LENGTH=5
#typeset -g POWERLEVEL9K_TIME_FORMAT="%D{%H:%M \uE868 %d.%m.%y}"
## Segment
typeset -g POWERLEVEL9K_LEFT_SEGMENT_SEPARATOR=$'\uE0B0' # ๎ฐ or '\uE0B4' ๎ด or '\uE0B8' ๎ธ or '\uE0BC' ๎ผ or '\uE0C0' ๎
typeset -g POWERLEVEL9K_LEFT_SEGMENT_END_SEPARATOR=' ' # or '\uF105' ๏
or '\uF12D' ๏ญ
typeset -g POWERLEVEL9K_LEFT_SUBSEGMENT_SEPARATOR=$' \uE0B1' # ๎ฑ or '\uE0B5' ๎ต or '\uE0B9' ๎น or '\uE0BD' ๎ฝ or '\uE0C1' ๎
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_PREFIX="โฑ" # or '\u256D'$'\U2500' โญโ
typeset -g POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX="โณ " # or '\u251C'$'\U2500' โโ or '\u2570'$'\U2500 ' โฐโ
typeset -g POWERLEVEL9K_MULTILINE_NEWLINE_PROMPT_PREFIX='\u251C'$'\U2500' # โโ
typeset -g POWERLEVEL9K_MULTILINE_SECOND_PROMPT_PREFIX='\u251C'$'\U2500' # โโ
typeset -g POWERLEVEL9K_RIGHT_SEGMENT_SEPARATOR=$'\uE0B2' # ๎ฒ or '\uE0B6' ๎ถ or '\uE0BA' ๎บ or '\uE0BE' ๎พ or '\uE0C2' ๎
typeset -g POWERLEVEL9K_RIGHT_SUBSEGMENT_SEPARATOR=$'\uE0B3' # ๎ณ or '\uE0B7' ๎ท or '\uE0BB' ๎ป or '\uE0BF' ๎ฟ or '\uE0C3' ๎
## Etc: '\uE0C4' ๎, '\uE0C5' ๎
, '\uE0C6' ๎, '\uE0C7' ๎, '\uE0C8' ๎, '\uE0CA' ๎, '\uE0CC' ๎, '\uE0CD'
# '\uE0CE' ๎, '\uE0CF' ๎, '\uE0D0' ๎, '\uE0D1' ๎, '\uE0D2' ๎, '\uE0D4' ๎
## -- Icon Set ---------------------------------------------
_powerline-icon
## -- Color Set --------------------------------------------
_powerline-color
}
_powerline-nerd-single()
{
## -- Prompts Set ------------------------------------------
## Prompt
# init
_left_prompt() {
typeset -ga POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(context root_indicator dir dir_writable vcs)
if ! [[ -n ${SSH_CLIENT-} || -n ${SSH_TTY-} ||
$EUID -eq 0 ]]; then
typeset -ga POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(root_indicator dir dir_writable vcs)
fi
}
_left_prompt && add-zsh-hook precmd _left_prompt
typeset -ga POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(status background_jobs command_execution_time
"${ENV_PROMPT_ELEMENTS[@]}" history)
## Double-Lined Prompt
typeset -g POWERLEVEL9K_PROMPT_ON_NEWLINE=false
typeset -g POWERLEVEL9K_PROMPT_ADD_NEWLINE=true
typeset -g POWERLEVEL9K_RPROMPT_ON_NEWLINE=false
## Other Prompt
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_VERBOSE=true
typeset -g POWERLEVEL9K_STATUS_OK=true
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_THRESHOLD=0
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_PRECISION=2
#typeset -g POWERLEVEL9K_CHANGESET_HASH_LENGTH=6
#typeset -g POWERLEVEL9K_SHORTEN_STRATEGY="truncate_middle"
typeset -g POWERLEVEL9K_SHORTEN_DIR_LENGTH=5
#typeset -g POWERLEVEL9K_TIME_FORMAT="%D{%H:%M \uE868 %d.%m.%y}"
## Segment
typeset -g POWERLEVEL9K_LEFT_SEGMENT_SEPARATOR=$'\uE0B0' # ๎ฐ or '\uE0B4' ๎ด or '\uE0B8' ๎ธ or '\uE0BC' ๎ผ or '\uE0C0' ๎
typeset -g POWERLEVEL9K_LEFT_SEGMENT_END_SEPARATOR=' ' # or '\uF105' ๏
or '\uF12D' ๏ญ
typeset -g POWERLEVEL9K_LEFT_SUBSEGMENT_SEPARATOR=$' \uE0B1' # ๎ฑ or '\uE0B5' ๎ต or '\uE0B9' ๎น or '\uE0BD' ๎ฝ or '\uE0C1' ๎
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_PREFIX="โฑ" # or '\u256D'$'\U2500' โญโ
typeset -g POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX="โณ " # or '\u251C'$'\U2500' โโ or '\u2570'$'\U2500 ' โฐโ
typeset -g POWERLEVEL9K_MULTILINE_NEWLINE_PROMPT_PREFIX='\u251C'$'\U2500' # โโ
typeset -g POWERLEVEL9K_MULTILINE_SECOND_PROMPT_PREFIX='\u251C'$'\U2500' # โโ
typeset -g POWERLEVEL9K_RIGHT_SEGMENT_SEPARATOR=$'\uE0B2' # ๎ฒ or '\uE0B6' ๎ถ or '\uE0BA' ๎บ or '\uE0BE' ๎พ or '\uE0C2' ๎
typeset -g POWERLEVEL9K_RIGHT_SUBSEGMENT_SEPARATOR=$'\uE0B3' # ๎ณ or '\uE0B7' ๎ท or '\uE0BB' ๎ป or '\uE0BF' ๎ฟ or '\uE0C3' ๎
## Etc: '\uE0C4' ๎, '\uE0C5' ๎
, '\uE0C6' ๎, '\uE0C7' ๎, '\uE0C8' ๎, '\uE0CA' ๎, '\uE0CC' ๎, '\uE0CD'
# '\uE0CE' ๎, '\uE0CF' ๎, '\uE0D0' ๎, '\uE0D1' ๎, '\uE0D2' ๎, '\uE0D4' ๎
## -- Icon Set ---------------------------------------------
## Replace Icons
root=${root%\ root}
## Load Icons
_powerline-icon
## -- Color Set --------------------------------------------
_powerline-color
}
_simple-nerd()
{
# Original location: https://github.com/romkatv/dotfiles-public/blob/master/.purepower.
# If you copy this file, keep the link to the original and this sentence intact; you are encouraged
# to change everything else.
## -- Prompts Set ------------------------------------------
## Prompt
# init
_left_prompt() {
typeset -ga POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(dir vcs context dir_writable root_indicator
"${ENV_PROMPT_ELEMENTS[@]}" command_execution_time)
# not connected ssh, root user
if ! [[ -n ${SSH_CLIENT-} || -n ${SSH_TTY-} ||
$EUID -eq 0 ]]; then
typeset -ga POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(dir vcs dir_writable root_indicator
"${ENV_PROMPT_ELEMENTS[@]}" command_execution_time)
fi
}
_left_prompt && add-zsh-hook precmd _left_prompt
typeset -ga POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(background_jobs status)
## Double-Lined Prompt
vi_insert=$'\u276F' #โฏ
vi_cmd=$'\u276E' #โฎ
local p="\${\${\${KEYMAP:-0}:#vicmd}:+${${vi_insert//\\/\\\\}//\}/\\\}}}"
p+="\${\${\$((!\${#\${KEYMAP:-0}:#vicmd})):#0}:+${${vi_cmd//\\/\\\\}//\}/\\\}}}"
typeset -g POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX="%(?.%F{171}${p}%f.%F{160}${p}%f) "
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_PREFIX=$'\n'
typeset -g POWERLEVEL9K_PROMPT_ON_NEWLINE=true
typeset -g POWERLEVEL9K_RPROMPT_ON_NEWLINE=true
## Other Prompt
typeset -g POWERLEVEL9K_ALWAYS_SHOW_CONTEXT=false
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_VERBOSE=true
typeset -g POWERLEVEL9K_STATUS_OK=false
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_THRESHOLD=2
typeset -g POWERLEVEL9K_TRANSIENT_PROMPT=same-dir # off always
## Segment
typeset -g POWERLEVEL9K_CONTEXT_TEMPLATE=' %n@%m'
typeset -g POWERLEVEL9K_LEFT_SEGMENT_SEPARATOR=$'\u3000' # ใor (space)
typeset -g POWERLEVEL9K_LEFT_SEGMENT_END_SEPARATOR=''
typeset -g POWERLEVEL9K_LEFT_SUBSEGMENT_SEPARATOR=''
typeset -g POWERLEVEL9K_RIGHT_SEGMENT_SEPARATOR=' '
typeset -g POWERLEVEL9K_RIGHT_SUBSEGMENT_SEPARATOR=''
typeset -g POWERLEVEL9K_WHITESPACE_BETWEEN_LEFT_SEGMENTS=''
typeset -g POWERLEVEL9K_WHITESPACE_BETWEEN_RIGHT_SEGMENTS=''
## -- Icon Set ---------------------------------------------
## Replace Icons
background_jobs=$'\u3002' # ใ
carriage_return=''
execution_time=' '
lock=" $lock"
root='\uF09C' # ๏
vcs_branch=" $vcs_branch"
vcs_git=''
vcs_git_bitbucket=''
vcs_git_github=''
vcs_git_gitlab=''
vcs_hg=''
vcs_incoming_changes=$'\u21E3' # โฃ
vcs_outgoing_changes=$'\u21E1' # โก
vcs_remote_branch=$'\u21DD' # โ
vcs_staged=$'\b\uFF0B' # ๏ผ
vcs_stash=$'\b\uFF0A' # ๏ผ
vcs_svn=''
vcs_tag="$vcs_tag "
vcs_unstaged=$'\b\uFF01' # ๏ผ
vcs_untracked=$'\b\uFF1F' # ๏ผ
## Load Icons
_simple-icon
## -- Color Set --------------------------------------------
##-----Color Set
_simple-color
}
_simple-nerd-single()
{
# Original location: https://github.com/romkatv/dotfiles-public/blob/master/.purepower.
# If you copy this file, keep the link to the original and this sentence intact; you are encouraged
# to change everything else.
## -- Prompts Set ------------------------------------------
## Prompt
# init
_left_prompt() {
typeset -ga POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(context dir)
# not connected ssh, root user
if ! [[ -n ${SSH_CLIENT-} || -n ${SSH_TTY-} ||
$EUID -eq 0 ]]; then
typeset -ga POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(dir)
fi
}
_left_prompt && add-zsh-hook precmd _left_prompt
typeset -ga POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(dir_writable root_indicator command_execution_time background_jobs status vcs)
## Double-Lined Prompt
vi_insert=$'\u276F' #โฏ
vi_cmd=$'\u276E' #โฎ
local p="\${\${\${KEYMAP:-0}:#vicmd}:+${${vi_insert//\\/\\\\}//\}/\\\}}}"
p+="\${\${\$((!\${#\${KEYMAP:-0}:#vicmd})):#0}:+${${vi_cmd//\\/\\\\}//\}/\\\}}}"
typeset -g POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX="%(?.%F{171}${p}%f.%F{160}${p}%f) "
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_PREFIX=$'\n'
typeset -g POWERLEVEL9K_PROMPT_ON_NEWLINE=false
typeset -g POWERLEVEL9K_RPROMPT_ON_NEWLINE=false
## Other Prompt
typeset -g POWERLEVEL9K_ALWAYS_SHOW_CONTEXT=false
typeset -g POWERLEVEL9K_BACKGROUND_JOBS_VERBOSE=true
typeset -g POWERLEVEL9K_STATUS_OK=false
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_THRESHOLD=2
typeset -g POWERLEVEL9K_TRANSIENT_PROMPT=same-dir # off always
## Segment
typeset -g POWERLEVEL9K_CONTEXT_TEMPLATE='%n@%m '
typeset -g POWERLEVEL9K_LEFT_SEGMENT_SEPARATOR=''ใ
typeset -g POWERLEVEL9K_LEFT_SEGMENT_END_SEPARATOR=$POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX
typeset -g POWERLEVEL9K_LEFT_SUBSEGMENT_SEPARATOR=''
typeset -g POWERLEVEL9K_RIGHT_SEGMENT_SEPARATOR=''
typeset -g POWERLEVEL9K_RIGHT_SUBSEGMENT_SEPARATOR=' '
typeset -g POWERLEVEL9K_WHITESPACE_BETWEEN_LEFT_SEGMENTS=''
typeset -g POWERLEVEL9K_WHITESPACE_BETWEEN_RIGHT_SEGMENTS=''
## -- Icon Set ---------------------------------------------
## Replace Icons
background_jobs=$'\u3002' # ใ
carriage_return=''
execution_time=' '
lock="$lock "
root='\uF09C ' # ๏
vcs_branch=" $vcs_branch"
vcs_git=''
vcs_git_bitbucket=''
vcs_git_github=''
vcs_git_gitlab=''
vcs_hg=''
vcs_incoming_changes=$'\u21E3' # โฃ
vcs_outgoing_changes=$'\u21E1' # โก
vcs_remote_branch=$'\u21DD' # โ
vcs_staged=$'\uFF0B' # ๏ผ
vcs_stash=$'\uFF0A' # ๏ผ
vcs_svn=''
vcs_tag="$vcs_tag "
vcs_unstaged=$'\uFF01' # ๏ผ
vcs_untracked=$'\uFF1F' # ๏ผ
## Load Icons
_simple-icon
## -- Color Set --------------------------------------------
_simple-color
}