[Org files] Formatted org files to look better with new org config

This commit is contained in:
Lucien Cartier-Tilet 2020-11-13 15:18:43 +01:00
parent e3880c48b1
commit 3a1015b9e7
Signed by: phundrak
GPG Key ID: BD7789E705CB8DCA
14 changed files with 5326 additions and 6531 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1794,7 +1794,6 @@ One of the amazing features of org-mode is its literary programming capacities b
| sass |
| scheme |
| shell |
| swift |
#+NAME: org-babel-languages-gen
#+BEGIN_SRC emacs-lisp :exports none :tangle no :var languages=org-babel-languages-table[,0] :cache yes :results replace
@ -1803,7 +1802,7 @@ One of the amazing features of org-mode is its literary programming capacities b
"\n")
#+END_SRC
#+RESULTS[d8ef67cfac36191c43e0f20b9c0a024cb1e9413e]: org-babel-languages-gen
#+RESULTS[cf8b81f0da6306f8131e34be6d3742248fdb057b]: org-babel-languages-gen
#+begin_example
(C . t)
(dot . t)
@ -1815,7 +1814,6 @@ One of the amazing features of org-mode is its literary programming capacities b
(sass . t)
(scheme . t)
(shell . t)
(swift . t)
#+end_example
The corresponding code is as follows:
@ -2604,7 +2602,6 @@ I also want to always be in ~visual-line-mode~ so Emacs soft-wraps lines that ar
I also want for some non-programming modes to enable a hard-limit in terms of how many characters can fit on one line. The modes that benefit are ~message-mode~, ~org-mode~, ~text-mode~ and ~markdown-mode~.
#+BEGIN_SRC emacs-lisp
(mapc (lambda (x)
(add-hook x 'auto-fill-mode)
(add-hook x 'visual-line-mode))
'(message-mode-hook
text-mode-hook
@ -3005,16 +3002,15 @@ I want to see by default how much battery my computer has, so lets enable it:
:END:
As I will always say, orgmode is an amazing piece of software that deserves particular care and love. That is why I want to give it a unique look and feel compared to the rest of my Emacs configuration, in order to make it feel much more comfortable.
In order to make org-mode even sexier, lets enable ~variable-pitch-mode~ for org-mode so we can get some proportional font:
In order to make org-mode even sexier, lets enable ~variable-pitch-mode~ for org-mode so we can get some proportional font. Ill also remove ~auto-fill-mode~ which seems to stick to Orgmode like hell and I dont know why.
#+BEGIN_SRC emacs-lisp
(add-hook 'org-mode-hook 'variable-pitch-mode)
(add-hook 'org-mode-hook 'visual-line-mode)
(message "coucou")
(remove-hook 'org-mode-hook 'auto-fill-mode)
#+END_SRC
Fonts will play an important part in this, but so will colors and font size. The following code is largely based on the one found [[https://zzamboni.org/post/beautifying-org-mode-in-emacs/][on this blog post]].
#+BEGIN_SRC emacs-lisp
(message "Setting up some beautiful org-mode")
(let* ((font `(:font "Charis SIL"))
(head `(:inherit default :weight bold))
(fixed `(:inherit fixed-pitch :height 0.8)))
@ -3044,7 +3040,6 @@ Fonts will play an important part in this, but so will colors and font size. The
`(org-link ((t (:foreground ,phundrak/nord8 :underline t))))
'(org-meta-line ((t (:inherit (font-lock-comment-face fixed-pitch) :height 0.8))))
'(org-special-keyword ((t (:inherit (font-lock-comment-face fixed-pitch)))))))
(message "Org-mode is now beautiful")
#+END_SRC
Finally, lets limit the width of images inlined in org buffers to 400px:

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -9,69 +9,51 @@
:PROPERTIES:
:CUSTOM_ID: Presentation-981f2f04
:END:
This is my collection of dotfiles for my daily GNU/Linux environment, tweaked
to my liking. If you wish to get the same setup as mine, follow the
instructions below.
This is my collection of dotfiles for my daily GNU/Linux environment, tweaked to my liking. If you wish to get the same setup as mine, follow the instructions below.
For starters, here is the link to all the pages on my website that you might
find interesting. Ill describe them in more details below.
- [[file:installation.org][Arch Linux bootstrap script]]
- [[file:awesome.org][AwesomeWM configuration]]
- [[file:bin.org][Custom scripts]]
- [[file:spacemacs.org][Emacs (Spacemacs) configuration]]
- [[file:fish.org][Fish shell configuration]]
- [[file:i3.org][i3 configuration]] (deprecated)
- [[file:nano.org][Nano configuration]] (deprecated)
- [[file:ncmpcpp.org][ncmpcpp configuration]] (work in progress)
- [[file:neofetch.org][Neofetch configuration]]
- [[file:picom.org][Picom configuration]] (new fork of Compton)
- [[file:polybar.org][Polybar configuration]] (deprecated)
- [[file:rustfmt.org][Rustfmt configuration]]
- [[file:tmux.org][Tmux configuration]]
For starters, here is the link to all the pages on my website that you might find interesting. Ill describe them in more details below.
- [[file:installation.org][Arch Linux bootstrap script]]
- [[file:awesome.org][AwesomeWM configuration]]
- [[file:bin.org][Custom scripts]]
- [[file:spacemacs.org][Emacs (Spacemacs) configuration]]
- [[file:fish.org][Fish shell configuration]]
- [[file:i3.org][i3 configuration]] (deprecated)
- [[file:nano.org][Nano configuration]] (deprecated)
- [[file:ncmpcpp.org][ncmpcpp configuration]] (work in progress)
- [[file:neofetch.org][Neofetch configuration]]
- [[file:picom.org][Picom configuration]] (new fork of Compton)
- [[file:polybar.org][Polybar configuration]] (deprecated)
- [[file:rustfmt.org][Rustfmt configuration]]
- [[file:tmux.org][Tmux configuration]]
As you can see, I personally use [[https://fishshell.com/][fish]] as my shell of choice, and [[https://www.gnu.org/software/emacs/][Emacs]] 28.0
(using the ~native-comp~ branch) using [[http://spacemacs.org][Spacemacs]] (still with Emacs keybinding
in Insert mode but with Evil in Normal mode) as my main text editor.
As you can see, I personally use [[https://fishshell.com/][fish]] as my shell of choice, and [[https://www.gnu.org/software/emacs/][Emacs]] 28.0 (using the ~native-comp~ branch) using [[http://spacemacs.org][Spacemacs]] (still with Emacs keybinding in Insert mode but with Evil in Normal mode) as my main text editor.
When it comes to my graphical UI, I do not have any desktop environment.
Instead, I have a tiling window manager, AwesomeWM. The historical first on my
configuration is [[https://github.com/Airblader/i3][i3-gaps]], an [[https://i3wm.org/][i3]] fork by [[https://github.com/Airblader/i3][Airblader]] with which I use two bars
generated by [[https://polybar.github.io/][Polybar]]. It used [[https://github.com/dylanaraps/pywal][pywal]] to define their color scheme, as well as
[[https://github.com/davatorium/rofi][rofi]]s color scheme. My other TWM and the one I currently use is [[https://awesomewm.org/][AwesomeWM]].
When it comes to my graphical UI, I do not have any desktop environment. Instead, I have a tiling window manager, AwesomeWM. The historical first on my configuration is [[https://github.com/Airblader/i3][i3-gaps]], an [[https://i3wm.org/][i3]] fork by [[https://github.com/Airblader/i3][Airblader]] with which I use two bars generated by [[https://polybar.github.io/][Polybar]]. It used [[https://github.com/dylanaraps/pywal][pywal]] to define their color scheme, as well as [[https://github.com/davatorium/rofi][rofi]]s color scheme. My other TWM and the one I currently use is [[https://awesomewm.org/][AwesomeWM]].
Finally, you can find my configuration for my ErgodoxEZ keyboard [[https://configure.ergodox-ez.com/ergodox-ez/layouts/5WrVw/latest/0][here]]. It is
optimized for usage with the Bépo layout set as a software layout, and for
shortcuts from i3.
Finally, you can find my configuration for my ErgodoxEZ keyboard [[https://configure.ergodox-ez.com/ergodox-ez/layouts/5WrVw/latest/0][here]]. It is optimized for usage with the Bépo layout set as a software layout, and for shortcuts from i3.
* Screenshots
:PROPERTIES:
:CUSTOM_ID: Screenshots-51f1cef3
:END:
#+CAPTION: Desktop with Neofetch in the terminal
[[./img/neofetch.png.webp]]
#+CAPTION: Desktop with Neofetch in the terminal
[[./img/neofetch.png.webp]]
#+CAPTION: Desktop with Emacs opened
[[./img/emacs.png.webp]]
#+CAPTION: Desktop with Emacs opened
[[./img/emacs.png.webp]]
#+CAPTION: Desktop with Rofi
[[./img/rofi.png.webp]]
#+CAPTION: Desktop with Rofi
[[./img/rofi.png.webp]]
* Features
:PROPERTIES:
:CUSTOM_ID: Features-5ab2a2c0
:END:
- Emacs configuration perfectly tailored for my own use
- Beautiful and comfy i3 and polybar configuration
- And enough information below to get basically the same distro install as I
have on my main computer and my travel laptop.
- Emacs configuration perfectly tailored for my own use
- Beautiful and comfy i3 and polybar configuration
- And enough information below to get basically the same distro install as I have on my main computer and my travel laptop.
Most of the org files you will find in this repos are the actual source code
of much of my config files. For instance, the bootstrap found in
[[file:installation.org][installation.org]] exports almost all of its code snippets to
[[file:.config/yadm/bootstrap][.config/yadm/bootstrap]] thanks to =M-x org-babel-tangle= from within Emacs.
Below I will also present and comment some of my short config files which do
not deserve to have a full org file dedicated to them.
Most of the org files you will find in this repos are the actual source code of much of my config files. For instance, the bootstrap found in [[file:installation.org][installation.org]] exports almost all of its code snippets to [[file:.config/yadm/bootstrap][.config/yadm/bootstrap]] thanks to =M-x org-babel-tangle= from within Emacs. Below I will also present and comment some of my short config files which do not deserve to have a full org file dedicated to them.
** Tiling Window Managers
:PROPERTIES:
@ -81,25 +63,19 @@
:PROPERTIES:
:CUSTOM_ID: Features-Tiling_Window_Managers-AwesomeWM-2eac61a9
:END:
AwesomeWM is the TWM I use the most on my computer between itself and i3. My
configuration for it is documented in detail in its corresponding document,
which you can find [[file:awesome.org][here]].
AwesomeWM is the TWM I use the most on my computer between itself and i3. My configuration for it is documented in detail in its corresponding document, which you can find [[file:awesome.org][here]].
*** i3 configuration (Deprecated)
:PROPERTIES:
:CUSTOM_ID: Features-Tiling_Window_Managers-i3_configuration-9c92e43c
:END:
The i3 configuration is detailed in its corresponding README which you can
find [[file:i3.org][here]]. Be aware I do not use i3 anymore, and I will not update it until
I may someday use it again. This was deprecated on August 22nd, 2020.
The i3 configuration is detailed in its corresponding README which you can find [[file:i3.org][here]]. Be aware I do not use i3 anymore, and I will not update it until I may someday use it again. This was deprecated on August 22nd, 2020.
** Polybar config (Deprecated)
:PROPERTIES:
:CUSTOM_ID: Features-Polybar_config_(Deprecated)-c8f95774
:END:
My annotated polybar config can be found [[file:polybar.org][here]], if you wish to use it. Be
aware I do not use polybar anymore, and I will not update it until I may
someday use it again. This was deprecated on August 22nd, 2020.
My annotated polybar config can be found [[file:polybar.org][here]], if you wish to use it. Be aware I do not use polybar anymore, and I will not update it until I may someday use it again. This was deprecated on August 22nd, 2020.
** Graphical tweaks
:PROPERTIES:
@ -118,207 +94,191 @@
:HEADER-ARGS: :mkdirp yes :tangle ~/.gtkrc-2.0
:CUSTOM_ID: Features-Graphical_tweaks-GTK_Settings-GTK2-General_configuration-eb1f1f3c
:END:
This file is tangled at ~$HOME/.gtkrc-2.0~. This is an equivalent for the
GTK3 configuration file you will see below, and it shares most of its
settings. First, lets select the Nordic theme for GTK2. Lets also set
the icon theme.
#+BEGIN_SRC conf-unix
# -*- mode: unix-config -*-
gtk-theme-name="Nordic"
gtk-icon-theme-name="Flat-Remix-Dark"
#+END_SRC
This file is tangled at ~$HOME/.gtkrc-2.0~. This is an equivalent for the GTK3 configuration file you will see below, and it shares most of its settings. First, lets select the Nordic theme for GTK2. Lets also set the icon theme.
#+BEGIN_SRC conf-unix
# -*- mode: unix-config -*-
gtk-theme-name="Nordic"
gtk-icon-theme-name="Flat-Remix-Dark"
#+END_SRC
#+BEGIN_SRC conf-unix
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle="hintslight"
#+END_SRC
#+BEGIN_SRC conf-unix
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle="hintslight"
#+END_SRC
This changes the shortcuts in menu, lets also make the menus snappier.
#+BEGIN_SRC conf-unix
gtk-can-change-accels=1
gtk-menu-bar-popup-delay=0
gtk-menu-popdown-delay=0
gtk-menu-popup-delay=0
#+END_SRC
This changes the shortcuts in menu, lets also make the menus snappier.
#+BEGIN_SRC conf-unix
gtk-can-change-accels=1
gtk-menu-bar-popup-delay=0
gtk-menu-popdown-delay=0
gtk-menu-popup-delay=0
#+END_SRC
***** Filechooser
:PROPERTIES:
:HEADER-ARGS: :mkdirp yes :tangle ~/.config/gtk-2.0/gtkfilechooser.ini
:CUSTOM_ID: Features-Graphical_tweaks-GTK_Settings-GTK2-Filechooser-389f040d
:END:
#+BEGIN_SRC conf-unix
[Filechooser Settings]
#+END_SRC
#+BEGIN_SRC conf-unix
[Filechooser Settings]
#+END_SRC
The first option alows me to open the file chooser in the current working
directory:
#+BEGIN_SRC conf-unix
StartupMode=cwd
#+END_SRC
The first option alows me to open the file chooser in the current working directory:
#+BEGIN_SRC conf-unix
StartupMode=cwd
#+END_SRC
Next, setting the location mode to ~path-bar~ will show the path as buttons
that can be clicked rather than the full path.
#+BEGIN_SRC conf-unix
LocationMode=path-bar
#+END_SRC
Next, setting the location mode to ~path-bar~ will show the path as buttons that can be clicked rather than the full path.
#+BEGIN_SRC conf-unix
LocationMode=path-bar
#+END_SRC
With this configuration, by default we wont see hidden files.
#+BEGIN_SRC conf-unix
ShowHidden=true
#+END_SRC
With this configuration, by default we wont see hidden files.
#+BEGIN_SRC conf-unix
ShowHidden=true
#+END_SRC
And we'll also see the size of the visible files.
#+BEGIN_SRC conf-unix
ShowSizeColumn=true
#+END_SRC
And we'll also see the size of the visible files.
#+BEGIN_SRC conf-unix
ShowSizeColumn=true
#+END_SRC
Now, lets choose the geometry of our file picker. These two first lines
set where the file picker appears:
#+BEGIN_SRC conf-unix
GeometryX=566
GeometryY=202
#+END_SRC
Now, lets choose the geometry of our file picker. These two first lines set where the file picker appears:
#+BEGIN_SRC conf-unix
GeometryX=566
GeometryY=202
#+END_SRC
And these two describe the size of the window:
#+BEGIN_SRC conf-unix
GeometryWidth=800
GeometryHeight=400
#+END_SRC
And these two describe the size of the window:
#+BEGIN_SRC conf-unix
GeometryWidth=800
GeometryHeight=400
#+END_SRC
With these two lines, we set how our files are sorted: by name, and in the
ascending order.
#+BEGIN_SRC conf-unix
SortColumn=name
SortOrder=ascending
#+END_SRC
With these two lines, we set how our files are sorted: by name, and in the ascending order.
#+BEGIN_SRC conf-unix
SortColumn=name
SortOrder=ascending
#+END_SRC
Our default view mode is a list of files:
#+BEGIN_SRC conf-unix
ViewMode=list-view
#+END_SRC
Our default view mode is a list of files:
#+BEGIN_SRC conf-unix
ViewMode=list-view
#+END_SRC
And finally, setting our icon view scale to ~-1~ sets the icon view to the
max size.
#+BEGIN_SRC conf-unix
IconViewScale=-1
#+END_SRC
And finally, setting our icon view scale to ~-1~ sets the icon view to the max size.
#+BEGIN_SRC conf-unix
IconViewScale=-1
#+END_SRC
**** GTK3
:PROPERTIES:
:HEADER-ARGS: :mkdirp yes :tangle ~/.config/gtk-3.0/settings.ini
:CUSTOM_ID: Features-Graphical_tweaks-GTK_Settings-GTK3-3d6cba86
:END:
The following file helps me choosing the aspect of various GTK+ 3 software,
including their theme and icons. First, lets declare the header:
#+BEGIN_SRC conf-unix
[Settings]
#+END_SRC
The following file helps me choosing the aspect of various GTK+ 3 software, including their theme and icons. First, lets declare the header:
#+BEGIN_SRC conf-unix
[Settings]
#+END_SRC
Now, lets hint to GTK that I prefer dark themes. This can have an
influence also on some websites that can detect this preference and
therefore set their own theme to dark by themselves.
#+BEGIN_SRC conf-unix
gtk-application-prefer-dark-theme = true
#+END_SRC
Now, lets hint to GTK that I prefer dark themes. This can have an influence also on some websites that can detect this preference and therefore set their own theme to dark by themselves.
#+BEGIN_SRC conf-unix
gtk-application-prefer-dark-theme = true
#+END_SRC
Next, the icon theme is the Flat Remix Dark icon theme:
#+BEGIN_SRC conf-unix
gtk-icon-theme-name = Flat-Remix-Dark
#+END_SRC
Next, the icon theme is the Flat Remix Dark icon theme:
#+BEGIN_SRC conf-unix
gtk-icon-theme-name = Flat-Remix-Dark
#+END_SRC
Now, the general theme for GTK3 is Nordic.
#+BEGIN_SRC conf-unix
gtk-theme-name = Nordic
#+END_SRC
Now, the general theme for GTK3 is Nordic.
#+BEGIN_SRC conf-unix
gtk-theme-name = Nordic
#+END_SRC
#+BEGIN_SRC conf-unix
gtk-can-change-accels=1
gtk-menu-bar-popup-delay=0
gtk-menu-popdown-delay=0
gtk-menu-popup-delay=0
#+END_SRC
#+BEGIN_SRC conf-unix
gtk-can-change-accels=1
gtk-menu-bar-popup-delay=0
gtk-menu-popdown-delay=0
gtk-menu-popup-delay=0
#+END_SRC
#+BEGIN_SRC conf-unix
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle=hintslight
# gtk-xft-rgba=rgb
#+END_SRC
#+BEGIN_SRC conf-unix
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle=hintslight
# gtk-xft-rgba=rgb
#+END_SRC
Since window decorations are handled by my WMs, I will leave this variable
empty.
#+BEGIN_SRC conf-unix
gtk-decoration-layout=
#+END_SRC
Since window decorations are handled by my WMs, I will leave this variable empty.
#+BEGIN_SRC conf-unix
gtk-decoration-layout=
#+END_SRC
*** Picom (Compton)
:PROPERTIES:
:CUSTOM_ID: Features-Graphical_tweaks-Picom-b5b9a4dd
:END:
Picom is a standalone compositor for Xorg, and the successor to Compton,
itself successor to xcompmgr-dana, itself a fork of xcompmgr. You can find
my Picom configuration [[file:picom.org][here]].
Picom is a standalone compositor for Xorg, and the successor to Compton, itself successor to xcompmgr-dana, itself a fork of xcompmgr. You can find my Picom configuration [[file:picom.org][here]].
*** Xresources
:PROPERTIES:
:HEADER-ARGS: :mkdirp yes :tangle ~/.Xresources :exports code
:CUSTOM_ID: Features-Graphical_tweaks-Xresources-8b622de1
:END:
My Xresources file is very short. Indeed, it only contains two lines which
are dedicated to my =st= terminal to set its font and shell. The font is set
as follows.
#+BEGIN_SRC conf
st.font: Fantasque Sans Mono:size=10:antialias=true
#+END_SRC
I can also set the transparency of st (my terminal emulator) like so:
#+BEGIN_SRC conf
st.alpha: 0.85
#+END_SRC
My Xresources file is very short. Indeed, it only contains two lines which are dedicated to my =st= terminal to set its font and shell. The font is set as follows.
#+BEGIN_SRC conf
st.font: Fantasque Sans Mono:size=10:antialias=true
#+END_SRC
Next is the declaration of my color theme. It is based on the [[https://www.nordtheme.com/][Nord]] theme,
from their [[https://github.com/arcticicestudio/nord-xresources/][Git repository]].
#+BEGIN_SRC conf
#define nord0 #2E3440
#define nord1 #3B4252
#define nord2 #434C5E
#define nord3 #4C566A
#define nord4 #D8DEE9
#define nord5 #E5E9F0
#define nord6 #ECEFF4
#define nord7 #8FBCBB
#define nord8 #88C0D0
#define nord9 #81A1C1
#define nord10 #5E81AC
#define nord11 #BF616A
#define nord12 #D08770
#define nord13 #EBCB8B
#define nord14 #A3BE8C
#define nord15 #B48EAD
I can also set the transparency of st (my terminal emulator) like so:
#+BEGIN_SRC conf
st.alpha: 0.85
#+END_SRC
,*.foreground: nord4
,*.background: nord0
,*.cursorColor: nord4
,*fading: 35
,*fadeColor: nord3
Next is the declaration of my color theme. It is based on the [[https://www.nordtheme.com/][Nord]] theme, from their [[https://github.com/arcticicestudio/nord-xresources/][Git repository]].
#+BEGIN_SRC conf
#define nord0 #2E3440
#define nord1 #3B4252
#define nord2 #434C5E
#define nord3 #4C566A
#define nord4 #D8DEE9
#define nord5 #E5E9F0
#define nord6 #ECEFF4
#define nord7 #8FBCBB
#define nord8 #88C0D0
#define nord9 #81A1C1
#define nord10 #5E81AC
#define nord11 #BF616A
#define nord12 #D08770
#define nord13 #EBCB8B
#define nord14 #A3BE8C
#define nord15 #B48EAD
,*.color0: nord1
,*.color1: nord11
,*.color2: nord14
,*.color3: nord13
,*.color4: nord9
,*.color5: nord15
,*.color6: nord8
,*.color7: nord5
,*.color8: nord3
,*.color9: nord11
,*.color10: nord14
,*.color11: nord13
,*.color12: nord9
,*.color13: nord15
,*.color14: nord7
,*.color15: nord6
#+END_SRC
,*.foreground: nord4
,*.background: nord0
,*.cursorColor: nord4
,*fading: 35
,*fadeColor: nord3
,*.color0: nord1
,*.color1: nord11
,*.color2: nord14
,*.color3: nord13
,*.color4: nord9
,*.color5: nord15
,*.color6: nord8
,*.color7: nord5
,*.color8: nord3
,*.color9: nord11
,*.color10: nord14
,*.color11: nord13
,*.color12: nord9
,*.color13: nord15
,*.color14: nord7
,*.color15: nord6
#+END_SRC
** Text and source code editing
:PROPERTIES:
@ -328,47 +288,36 @@
:PROPERTIES:
:CUSTOM_ID: Features-Text_and_source_code_editing-Emacs_configuration-ef937102
:END:
Emacs is my main text editor, which I use for almost everything. Because,
you know…
#+begin_quote
Emacs is a great operating system, it just lacks a good text editor.
#+end_quote
Emacs is my main text editor, which I use for almost everything. Because, you know…
#+begin_quote
Emacs is a great operating system, it just lacks a good text editor.
#+end_quote
You can find my Emacs config, based on Spacemacs, in my [[https://labs.phundrak.com/phundrak/dotfiles/src/branch/master/.spacemacs][.spacemacs]] file, and
my user configuration in my [[file:emacs.org][emacs.org]] file.
You can find my Emacs config, based on Spacemacs, in my [[https://labs.phundrak.com/phundrak/dotfiles/src/branch/master/.spacemacs][.spacemacs]] file, and my user configuration in my [[file:emacs.org][emacs.org]] file.
*** Nano (deprecated)
:PROPERTIES:
:CUSTOM_ID: Features-Text_and_source_code_editing-Nano-a9d4839f
:END:
Although it is a very simple piece of software, nano does offer some
customization. Mine can be found in my [[file:~/org/config-website/nano.org][nano.org]] file. Be aware I do not use
nano anymore, and I will not update it until I may someday use it again.
This was deprecated on August 28th, 2020.
Although it is a very simple piece of software, nano does offer some customization. Mine can be found in my [[file:~/org/config-website/nano.org][nano.org]] file. Be aware I do not use nano anymore, and I will not update it until I may someday use it again. This was deprecated on August 28th, 2020.
*** Rustfmt
:PROPERTIES:
:CUSTOM_ID: Features-Text_and_source_code_editing-Rustfmt-2c4ac0b3
:END:
You can find my Rustfmt configuration [[file:rustfmt.org][here]].
You can find my Rustfmt configuration [[file:rustfmt.org][here]].
** Custom scripts in =PATH=
:PROPERTIES:
:CUSTOM_ID: Features-Custom_scripts_in_=PATH=-043e8c8e
:END:
I have written some scripts that help me daily accomplish some simple tasks,
like mounting and unmounting a drive or Android device, an emoji picker, a
utility to set up my Wacom tablet, and so on. You can find them stored in my
[[file:bin.org][bin.org]] file along with their detailed explanation in the README placed in
the same folder —which is actually their source code once the org-mode file
gets tangled.
I have written some scripts that help me daily accomplish some simple tasks, like mounting and unmounting a drive or Android device, an emoji picker, a utility to set up my Wacom tablet, and so on. You can find them stored in my [[file:bin.org][bin.org]] file along with their detailed explanation in the README placed in the same folder —which is actually their source code once the org-mode file gets tangled.
** Fish configuration with useful abbreviations
:PROPERTIES:
:CUSTOM_ID: Features-Fish_configuration_with_useful_abbreviations-c71ffba0
:END:
You can also find in my Fish shell configuration in my [[file:~/org/config-website/fish.org][fish.org]] file, which
contains my usual abbreviations.
You can also find in my Fish shell configuration in my [[file:~/org/config-website/fish.org][fish.org]] file, which contains my usual abbreviations.
** And some minor configuration files
:PROPERTIES:
@ -379,85 +328,69 @@
:HEADER-ARGS: :mkdirp yes :tangle ~/.signature
:CUSTOM_ID: Features-And_some_minor_configuration_files-Email_signature-8c5f2218
:END:
This file gets inserted automatically at the end of my emails.
#+BEGIN_SRC text
Lucien “Phundrak” Cartier-Tilet
Étudiant en Master Informatique, Tuteur, Université Paris 8
https://phundrak.com (Français)
https://phundrak.com/en (English)
This file gets inserted automatically at the end of my emails.
#+BEGIN_SRC text
Lucien “Phundrak” Cartier-Tilet
Étudiant en Master Informatique, Tuteur, Université Paris 8
https://phundrak.com (Français)
https://phundrak.com/en (English)
Sent from GNU/Emacs
#+END_SRC
Sent from GNU/Emacs
#+END_SRC
*** Global gitignore
:PROPERTIES:
:HEADER-ARGS: :mkdirp yes :tangle ~/.gitignore_global
:CUSTOM_ID: Features-And_some_minor_configuration_files-Global_gitignore-42467108
:END:
Sometimes, there are some lines that always reappear in gitignores. So,
instead of always adding them, let git now that some elements are to be
ignored by default, hence the [[file:.gitignore_global][~/.gitignore_global]] file. First, we dont want
nanos backup files.
#+BEGIN_SRC text
~*
#+END_SRC
Sometimes, there are some lines that always reappear in gitignores. So, instead of always adding them, let git now that some elements are to be ignored by default, hence the [[file:.gitignore_global][~/.gitignore_global]] file. First, we dont want nanos backup files.
#+BEGIN_SRC text
~*
#+END_SRC
And object files and output binaries generated by =gcc= and the likes arent
welcome either.
#+BEGIN_SRC text
,*.out
,*.o
#+END_SRC
And object files and output binaries generated by =gcc= and the likes arent welcome either.
#+BEGIN_SRC text
,*.out
,*.o
#+END_SRC
** Tmux configuration
:PROPERTIES:
:CUSTOM_ID: Features-Tmux_configuration-ce76e030
:END:
You can find my tmux configuration in [[file:tmux.org][tmux.org]]. It depends on the submodule
[[https://github.com/gpakosz/.tmux.git][.tmux]] by [[https://pempek.net/][Gregory Pakosz]].
You can find my tmux configuration in [[file:tmux.org][tmux.org]]. It depends on the submodule [[https://github.com/gpakosz/.tmux.git][.tmux]] by [[https://pempek.net/][Gregory Pakosz]].
* Dependencies
:PROPERTIES:
:CUSTOM_ID: Dependencies-ef5057dd
:END:
Of course, some dependencies are needed for my dotfiles to work well. Here is
a non-exhaustive list of software needed by these configuration files:
- [[https://www.gnu.org/software/emacs/][GNU/Emacs]] >= 26.2
- [[http://spacemacs.org][Spacemacs]] (develop branch)
- My [[https://labs.phundrak.com/phundrak/conlang-layer][conlanging layer]]
- [[https://github.com/venmos/w3m-layer][Venmos]] [[https://github.com/venmos/w3m-layer][w3m layer]]
- The [[https://fishshell.com/][Fish shell]], using [[https://github.com/jorgebucaran/fisher][fisher]]
- [[https://lukesmith.xyz/][Luke Smith]]s [[https://github.com/LukeSmithxyz/st][fork]] of [[https://st.suckless.org/][st]]
- [[https://resloved.info/][Resloved]]s [[https://github.com/resloved/i3][i3-gaps-rounded]] fork of [[https://github.com/Airblader/i3][Airblader]]s [[https://github.com/Airblader/i3][i3-gaps]], itself a fork of [[https://i3wm.org/][i3]]
- [[https://github.com/yshui/compton][Compton]], more specificaly [[https://github.com/tryone144/compton][Tryone]]s [[https://github.com/tryone144/compton][fork]]
- [[https://github.com/dylanaraps/pywal/][pywal]]
- [[https://tools.suckless.org/dmenu/][dmenu]]
- [[https://github.com/enkore/j4-dmenu-desktop][j4-dmenu-desktop]]
- [[https://github.com/davatorium/rofi][Rofi]]
- [[https://github.com/gpoore/minted][minted]]
- [[https://www.rust-lang.org/][Rust]] (stable and nightly)
- [[https://www.latex-project.org/][LaTeX]] and [[http://xetex.sourceforge.net/][XeTeX]] (=texlive= packages on Arch Linux)
- [[https://github.com/tmux/tmux][tmux]], based on [[https://github.com/gpakosz/.tmux][this repo]]s configuration by [[https://pempek.net/][Grégory Pakosz]].
- And a bunch of other stuff, see below
And some other stuff scattered around in my dotfiles.
Of course, some dependencies are needed for my dotfiles to work well. Here is a non-exhaustive list of software needed by these configuration files:
- [[https://www.gnu.org/software/emacs/][GNU/Emacs]] >= 26.2
- [[http://spacemacs.org][Spacemacs]] (develop branch)
- My [[https://labs.phundrak.com/phundrak/conlang-layer][conlanging layer]]
- [[https://github.com/venmos/w3m-layer][Venmos]] [[https://github.com/venmos/w3m-layer][w3m layer]]
- The [[https://fishshell.com/][Fish shell]], using [[https://github.com/jorgebucaran/fisher][fisher]]
- [[https://lukesmith.xyz/][Luke Smith]]s [[https://github.com/LukeSmithxyz/st][fork]] of [[https://st.suckless.org/][st]]
- [[https://tools.suckless.org/dmenu/][dmenu]]
- [[https://github.com/enkore/j4-dmenu-desktop][j4-dmenu-desktop]]
- [[https://github.com/davatorium/rofi][Rofi]]
- [[https://github.com/gpoore/minted][minted]]
- [[https://www.rust-lang.org/][Rust]] (stable and nightly)
- [[https://www.latex-project.org/][LaTeX]] and [[http://xetex.sourceforge.net/][XeTeX]] (=texlive= packages on Arch Linux)
- [[https://github.com/tmux/tmux][tmux]], based on [[https://github.com/gpakosz/.tmux][this repo]]s configuration by [[https://pempek.net/][Grégory Pakosz]].
- And a bunch of other stuff, see below
And some other stuff scattered around in my dotfiles.
BTW, I use Arch.
BTW, I use Arch.
* Installation
:PROPERTIES:
:CUSTOM_ID: Installation-9ec2ae86
:END:
For an installation walkthrough of my Arch Linux installation, check out my
[[file:installation.org][installation.org]] file where I walk you through the first manual steps and
through the bootstrap you can execute to automatically take care of a lot of
elements.
For an installation walkthrough of my Arch Linux installation, check out my [[file:installation.org][installation.org]] file where I walk you through the first manual steps and through the bootstrap you can execute to automatically take care of a lot of elements.
* Licence
:PROPERTIES:
:CUSTOM_ID: Licence-48911096
:END:
All of my dotfiles (and my dotfiles only) are available under the GNU GPLv3
Licence. Please consult [[file:LICENCE.md]] for more information. In short: you
are free to access, edit and redistribute all of my dotfiles under the same
licence and as allowed by the licence, and if you fuck up something, its your
own responsibility.
All of my dotfiles (and my dotfiles only) are available under the GNU GPLv3 Licence. Please consult [[file:LICENCE.md]] for more information. In short: you are free to access, edit and redistribute all of my dotfiles under the same licence and as allowed by the licence, and if you fuck up something, its your own responsibility.

File diff suppressed because it is too large Load Diff

View File

@ -10,134 +10,106 @@
:PROPERTIES:
:CUSTOM_ID: Introduction-7e535842
:END:
*Before proceeding, be aware that I deprecated this nano config on August
28th, 2020, meaning I wont update it anymore unless I use it again some day
in the future. I will keep it on my website though.*
*Before proceeding, be aware that I deprecated this nano config on August 28th, 2020, meaning I wont update it anymore unless I use it again some day in the future. I will keep it on my website though.*
I nowadays rarely use Nano as a text editor, since I mainly rely on Emacs for
all sorts of tasks, including quick file editing. However, at times, Emacs
wont work or wont be available, and I therefore need a lightweight, fast and
reliable text editor: Nano. And despite Nano being a simple piece of software,
it does offer some customization I cannot refuse. Here is how I configured it:
I nowadays rarely use Nano as a text editor, since I mainly rely on Emacs for all sorts of tasks, including quick file editing. However, at times, Emacs wont work or wont be available, and I therefore need a lightweight, fast and reliable text editor: Nano. And despite Nano being a simple piece of software, it does offer some customization I cannot refuse. Here is how I configured it:
* Configuration
:PROPERTIES:
:CUSTOM_ID: Configuration-b55668a7
:END:
When saving a file, create a backup file by adding a tilde (=~=) to the file's
name. And make and keep not just one backup file, but make and keep a uniquely
numbered one every time a file is saved — when backups are enabled with =set
backup= or =--backup= or =-B=. The uniquely numbered files are stored in the
directory =~/.cache/nano/backups/=.
#+BEGIN_SRC conf
set backup
set backupdir /home/phundrak/.cache/nano/backups/
#+END_SRC
When saving a file, create a backup file by adding a tilde (=~=) to the file's name. And make and keep not just one backup file, but make and keep a uniquely numbered one every time a file is saved — when backups are enabled with =set backup= or =--backup= or =-B=. The uniquely numbered files are stored in the directory =~/.cache/nano/backups/=.
#+BEGIN_SRC conf
set backup
set backupdir /home/phundrak/.cache/nano/backups/
#+END_SRC
Save a file by default in Unix format. This overrides nano's default behavior
of saving a file in the format that it had. (This option has no effect when
you also use =set noconvert=.)
#+BEGIN_SRC conf
set unix
#+END_SRC
Save a file by default in Unix format. This overrides nano's default behavior of saving a file in the format that it had. (This option has no effect when you also use =set noconvert=.)
#+BEGIN_SRC conf
set unix
#+END_SRC
** Keys behavior
:PROPERTIES:
:CUSTOM_ID: Configuration-Keys_behavior-c665fa36
:END:
Make the Home key smarter. When Home is pressed anywhere but at the very
beginning of non-whitespace characters on a line, the cursor will jump to
that beginning (either forwards or backwards). If the cursor is already at
that position, it will jump to the true beginning of the line.
#+BEGIN_SRC conf
set smarthome
#+END_SRC
Make the Home key smarter. When Home is pressed anywhere but at the very beginning of non-whitespace characters on a line, the cursor will jump to that beginning (either forwards or backwards). If the cursor is already at that position, it will jump to the true beginning of the line.
#+BEGIN_SRC conf
set smarthome
#+END_SRC
** Search
:PROPERTIES:
:CUSTOM_ID: Configuration-Search-6e458076
:END:
Do case-unsensitive searches by default.
#+BEGIN_SRC conf
unset casesensitive
#+END_SRC
Do case-unsensitive searches by default.
#+BEGIN_SRC conf
unset casesensitive
#+END_SRC
Do regular-expression searches by default. Regular expressions in =nano= are
of the extended type (ERE).
#+BEGIN_SRC conf
set regexp
#+END_SRC
Do regular-expression searches by default. Regular expressions in =nano= are of the extended type (ERE).
#+BEGIN_SRC conf
set regexp
#+END_SRC
** Visual settings
:PROPERTIES:
:CUSTOM_ID: Configuration-Visual_settings-9952f2ae
:END:
Use bold instead of reverse video for the title bar, status bar, key combos,
function tags, line numbers, and selected text. This can be overridden by
setting the options =titlecolor=, =statuscolor=, =keycolor=, =functioncolor=,
=numbercolor=, and =selectedcolor=.
#+BEGIN_SRC conf
set boldtext
#+END_SRC
Use bold instead of reverse video for the title bar, status bar, key combos, function tags, line numbers, and selected text. This can be overridden by setting the options =titlecolor=, =statuscolor=, =keycolor=, =functioncolor=, =numbercolor=, and =selectedcolor=.
#+BEGIN_SRC conf
set boldtext
#+END_SRC
Enable soft line wrapping for easier viewing of very long lines.
#+BEGIN_SRC conf
set softwrap
#+END_SRC
Enable soft line wrapping for easier viewing of very long lines.
#+BEGIN_SRC conf
set softwrap
#+END_SRC
When soft line wrapping is enabled, make it wrap lines at blank characters
(tabs and spaces) instead of always at the edge of the screen.
#+BEGIN_SRC conf
set atblanks
#+END_SRC
When soft line wrapping is enabled, make it wrap lines at blank characters (tabs and spaces) instead of always at the edge of the screen.
#+BEGIN_SRC conf
set atblanks
#+END_SRC
Display line numbers to the left of the text area.
#+BEGIN_SRC conf
set linenumbers
#+END_SRC
Display line numbers to the left of the text area.
#+BEGIN_SRC conf
set linenumbers
#+END_SRC
Constantly display the cursor position in the status bar. This overrides the
option =quickblank=.
#+BEGIN_SRC conf
set constantshow
#+END_SRC
Constantly display the cursor position in the status bar. This overrides the option =quickblank=.
#+BEGIN_SRC conf
set constantshow
#+END_SRC
** Whitespace settings
:PROPERTIES:
:CUSTOM_ID: Configuration-Whitespace_settings-8cef9cd7
:END:
Convert typed tabs to spaces. Sue me.
#+BEGIN_SRC conf
set tabstospaces
#+END_SRC
Convert typed tabs to spaces. Sue me.
#+BEGIN_SRC conf
set tabstospaces
#+END_SRC
Use a tab size of a certain amount of columns. The value of number must be
greater than 0. The default value is 8.
#+BEGIN_SRC conf
set tabsize 2
#+END_SRC
Use a tab size of a certain amount of columns. The value of number must be greater than 0. The default value is 8.
#+BEGIN_SRC conf
set tabsize 2
#+END_SRC
Automatically indent a newly created line to the same number of tabs and/or
spaces as the previous line (or as the next line if the previous line is the
beginning of a paragraph).
#+BEGIN_SRC conf
set autoindent
#+END_SRC
Automatically indent a newly created line to the same number of tabs and/or spaces as the previous line (or as the next line if the previous line is the beginning of a paragraph).
#+BEGIN_SRC conf
set autoindent
#+END_SRC
Remove trailing whitespace from wrapped lines when automatic hard-wrapping
occurs or when text is justified.
#+BEGIN_SRC conf
set trimblanks
#+END_SRC
Remove trailing whitespace from wrapped lines when automatic hard-wrapping occurs or when text is justified.
#+BEGIN_SRC conf
set trimblanks
#+END_SRC
** Included configuration file
:PROPERTIES:
:CUSTOM_ID: Configuration-Included_configuration_file-70b0f35b
:END:
Nano gives the opportunity to include some files located elsewhere. This is
why I added [[https://github.com/scopatz/nanorc][this repo]] as a submodule of my dotfiles so I can access a lot of
them at the same time. Since the submodule is cloned in =~/.config/nanorc=,
we can add only one line to include all of the =.nanorc= files.
#+BEGIN_SRC conf
include ~/.config/nano/nano-syntax/*.nanorc
#+END_SRC
Nano gives the opportunity to include some files located elsewhere. This is why I added [[https://github.com/scopatz/nanorc][this repo]] as a submodule of my dotfiles so I can access a lot of them at the same time. Since the submodule is cloned in =~/.config/nanorc=, we can add only one line to include all of the =.nanorc= files.
#+BEGIN_SRC conf
include ~/.config/nano/nano-syntax/*.nanorc
#+END_SRC

View File

@ -10,55 +10,47 @@
:PROPERTIES:
:CUSTOM_ID: Introduction-3e61ecfc
:END:
Ncmpcpp is a TUI front-end for MPD, with an UI very similar to Ncmpc. This is
my main MPD front-end after my i3 shortcuts. You can find below some
screenshots of how my current ncmpcpp configuration looks like.
Ncmpcpp is a TUI front-end for MPD, with an UI very similar to Ncmpc. This is
my main MPD front-end after my i3 shortcuts. You can find below some
screenshots of how my current ncmpcpp configuration looks like.
[[file:img/ncmpcpp-queue.png]]
[[file:img/ncmpcpp-queue.png]]
[[file:img/ncmpcpp-directory.png]]
[[file:img/ncmpcpp-directory.png]]
[[file:img/ncmpcpp-visualizer.png]]
[[file:img/ncmpcpp-visualizer.png]]
* Core Ncmpcpp settings
:PROPERTIES:
:CUSTOM_ID: Core_Ncmpcpp_settings-8cacae18
:END:
#+BEGIN_SRC conf :exports none
# -*- mode: conf -*-
#+END_SRC
#+BEGIN_SRC conf :exports none
# -*- mode: conf -*-
#+END_SRC
** Directories
:PROPERTIES:
:CUSTOM_ID: Core_Ncmpcpp_settings-Directories-28092c92
:END:
Ncmpcpp has two vital directories: the lyrics directory, and its own
configuration directory. The configuration for ncmpcpp is generally either in
~$HOME/.ncmpcpp/~ or in ~$XDG_CONFIG_HOME/ncmpcpp/~.
#+BEGIN_SRC conf
ncmpcpp_directory = ~/.config/ncmpcpp
#+END_SRC
Ncmpcpp has two vital directories: the lyrics directory, and its own configuration directory. The configuration for ncmpcpp is generally either in ~$HOME/.ncmpcpp/~ or in ~$XDG_CONFIG_HOME/ncmpcpp/~.
#+BEGIN_SRC conf
ncmpcpp_directory = ~/.config/ncmpcpp
#+END_SRC
When it comes to the lyrics, be sure to set the directory to the same
directory pointed at by Mpd.
#+BEGIN_SRC conf
lyrics_directory = ~/.lyrics
#+END_SRC
When it comes to the lyrics, be sure to set the directory to the same directory pointed at by Mpd.
#+BEGIN_SRC conf
lyrics_directory = ~/.lyrics
#+END_SRC
** MPD
:PROPERTIES:
:CUSTOM_ID: Core_Ncmpcpp_settings-MPD-a2a7452e
:END:
These settings tell ncmpcpp how to communicate with Mpd. Once again, be sure
to follow your own MPD settings. In my case, I am connecting to my local MPD
server, hence the ~localhost~ value of the variable below, and I did not
change the default port of MPD. My music is located at =~/Music=, and ncmpcpp
should connect pretty much immediately, although I allow a five seconds
timeout before ncmpcpp treats it as an error. Also, no crossfade please.
#+BEGIN_SRC conf
mpd_host = localhost
mpd_port = 6600
mpd_music_dir = ~/Music
mpd_connection_timeout = 5
mpd_crossfade_time = 0
#+END_SRC
These settings tell ncmpcpp how to communicate with Mpd. Once again, be sure to follow your own MPD settings. In my case, I am connecting to my local MPD server, hence the ~localhost~ value of the variable below, and I did not change the default port of MPD. My music is located at =~/Music=, and ncmpcpp should connect pretty much immediately, although I allow a five seconds timeout before ncmpcpp treats it as an error. Also, no crossfade please.
#+BEGIN_SRC conf
mpd_host = localhost
mpd_port = 6600
mpd_music_dir = ~/Music
mpd_connection_timeout = 5
mpd_crossfade_time = 0
#+END_SRC

View File

@ -11,101 +11,84 @@
:PROPERTIES:
:CUSTOM_ID: Introduction-5942aea3
:END:
[[https://github.com/dylanaraps/neofetch][Neofetch]] is a CLI utility used to display system information. It was written
in Bash, and thus its configuration file is written as a Bash script too. This
document was written with org-mode, and my configuration file is tangled from
the source blocks you will see below to ~~/.config/neofetch/config.conf~.
This configuration will only contain what I need. For any further information,
please refer to the [[https://github.com/dylanaraps/neofetch][original repository]] and [[https://github.com/dylanaraps/neofetch/wiki/Customizing-Info][its documentation]].
[[https://github.com/dylanaraps/neofetch][Neofetch]] is a CLI utility used to display system information. It was written in Bash, and thus its configuration file is written as a Bash script too. This document was written with org-mode, and my configuration file is tangled from the source blocks you will see below to ~~/.config/neofetch/config.conf~. This configuration will only contain what I need. For any further information, please refer to the [[https://github.com/dylanaraps/neofetch][original repository]] and [[https://github.com/dylanaraps/neofetch/wiki/Customizing-Info][its documentation]].
* The ~print_info~ functions
:PROPERTIES:
:CUSTOM_ID: The_print_info_functions-bb30763f
:END:
The ~print_info~ function is the function called by Neofetch in order to print
the system information it could fetch. In this function, well choose what to
display, and how. This function looks like this:
#+BEGIN_SRC sh :tangle no
print_info() {
# Print information here…
}
#+END_SRC
The ~print_info~ function is the function called by Neofetch in order to print the system information it could fetch. In this function, well choose what to display, and how. This function looks like this:
#+BEGIN_SRC sh :tangle no
print_info() {
# Print information here…
}
#+END_SRC
Generally, what we will display will be shown through the ~info~ function,
redefined inside Neofetch (this is not ~info(1)~). This ~info~ function
accepts one or two arguments. With one argument, such as with ~info memory~,
we can get a result that looks like ~5136MiB / 15873MiB~, while calling it
with two arguments will treat the first one as a prefix and the second one as
the interesting information; ~info "Memory" memory~ will look like
~Memory: 5136MiB / 15873MiB~. Here is what we want to display:
#+NAME: info-elements-table
| Prefix | Information | What it does |
|----------+-------------+-----------------------------------|
| | title | Username and hostname |
| | line_break | Insert a blank line |
| | cols | System theme |
| | line_break | Insert a blank line |
| OS | distro | Distribution name |
| Kernel | kernel | Kernel version |
| Uptime | uptime | Machine uptime |
| Packages | packages | Number of installed packages |
| Shell | shell | Users default shell |
| WM | wm | Users Window Manager |
| Terminal | term | Default terminal |
| CPU | cpu | CPU information |
| GPU | gpu | GPU information |
| Memory | memory | RAM information |
Generally, what we will display will be shown through the ~info~ function, redefined inside Neofetch (this is not ~info(1)~). This ~info~ function accepts one or two arguments. With one argument, such as with ~info memory~, we can get a result that looks like ~5136MiB / 15873MiB~, while calling it with two arguments will treat the first one as a prefix and the second one as the interesting information; ~info "Memory" memory~ will look like ~Memory: 5136MiB / 15873MiB~. Here is what we want to display:
#+NAME: info-elements-table
| Prefix | Information | What it does |
|----------+-------------+------------------------------|
| | title | Username and hostname |
| | line_break | Insert a blank line |
| | cols | System theme |
| | line_break | Insert a blank line |
| OS | distro | Distribution name |
| Kernel | kernel | Kernel version |
| Uptime | uptime | Machine uptime |
| Packages | packages | Number of installed packages |
| Shell | shell | Users default shell |
| WM | wm | Users Window Manager |
| Terminal | term | Default terminal |
| CPU | cpu | CPU information |
| GPU | gpu | GPU information |
| Memory | memory | RAM information |
#+NAME: info-elements-gen
#+BEGIN_SRC emacs-lisp :var table=info-elements-table :cache yes
(mapconcat (lambda (x)
(format "info %s%s"
(if (not (string= (car x) ""))
(format "\"%s\" " (car x))
"")
(cadr x)))
table
"\n")
#+END_SRC
#+NAME: info-elements-gen
#+BEGIN_SRC emacs-lisp :var table=info-elements-table :cache yes
(mapconcat (lambda (x)
(format "info %s%s"
(if (not (string= (car x) ""))
(format "\"%s\" " (car x))
"")
(cadr x)))
table
"\n")
#+END_SRC
#+RESULTS[1e66bf48472ad24006f0cb9dc9c86078764ba84e]: info-elements-gen
#+begin_example
info line_break
info title
info line_break
info cols
info line_break
info "OS" distro
info "Kernel" kernel
info "Uptime" uptime
info "Packages" packages
info "Shell" shell
info "WM" wm
info "Terminal" term
info "CPU" cpu
info "GPU" gpu
info "Memory" memory
info "Disks" disks
#+end_example
#+RESULTS[1e66bf48472ad24006f0cb9dc9c86078764ba84e]: info-elements-gen
#+begin_example
info line_break
info title
info line_break
info cols
info line_break
info "OS" distro
info "Kernel" kernel
info "Uptime" uptime
info "Packages" packages
info "Shell" shell
info "WM" wm
info "Terminal" term
info "CPU" cpu
info "GPU" gpu
info "Memory" memory
info "Disks" disks
#+end_example
Hence, the function looks like so:
#+BEGIN_SRC sh
print_info() {
<<info-elements-gen()>>
}
#+END_SRC
Hence, the function looks like so:
#+BEGIN_SRC sh
print_info() {
<<info-elements-gen()>>
}
#+END_SRC
Each of these modules can be tuned with the variables presented below.
Each of these modules can be tuned with the variables presented below.
* Information settings
:PROPERTIES:
:CUSTOM_ID: Information_settings-9d4cfe88
:END:
Each of the following variable tunes a function that can be called in
~print_info~ described above. It is possible to tune them by modifying this
document or the configuration file itself, and they can be overridden by the
command line with flags passed to ~neofetch~. I will divide these variables in
two main categories: hardware and software-related properties.
Each of the following variable tunes a function that can be called in ~print_info~ described above. It is possible to tune them by modifying this document or the configuration file itself, and they can be overridden by the command line with flags passed to ~neofetch~. I will divide these variables in two main categories: hardware and software-related properties.
** Software
:PROPERTIES:
@ -119,73 +102,72 @@
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-OS-Distro-cd12bc4f
:END:
This variable can shorten the output of the ~distro~ function.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--distro_shorthand~
- Supports :: Everything except Windows and Haiku
- Examples ::
- on :: ~Arch Linux~
- off :: ~Arch~
#+begin_src sh
distro_shorthand="off"
#+end_src
This variable can shorten the output of the ~distro~ function.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--distro_shorthand~
- Supports :: Everything except Windows and Haiku
- Examples ::
- on :: ~Arch Linux~
- off :: ~Arch~
#+begin_src sh
distro_shorthand="off"
#+end_src
It is possible to display when the distro has been installed on the computer.
It is possible to display when the distro has been installed on the computer.
**** Kernel
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-OS-Kernel-658cedce
:END:
The variable below can shorten the output ofh the ~kernel~ function.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--kernel_shorthand~
- Supports :: Everything except *BSDs (except PacBSD and PC-BSD)
- Examples ::
- on :: ~4.8.9-1-ARCH~
- off :: ~Linux 4.8.9-1-ARCH~
#+begin_src sh
kernel_shorthand="off"
#+end_src
The variable below can shorten the output ofh the ~kernel~ function.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--kernel_shorthand~
- Supports :: Everything except *BSDs (except PacBSD and PC-BSD)
- Examples ::
- on :: ~4.8.9-1-ARCH~
- off :: ~Linux 4.8.9-1-ARCH~
#+begin_src sh
kernel_shorthand="off"
#+end_src
**** OS Architecture
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-OS-OS_Architecture-2f60c93c
:END:
This variable can show or hide the OS architecture in the ~distro~ output.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--os_arch~
- Examples ::
- on :: ~Arch Linux x86_64~
- off :: ~Arch Linux~
#+begin_src sh
os_arch="off"
#+end_src
This variable can show or hide the OS architecture in the ~distro~ output.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--os_arch~
- Examples ::
- on :: ~Arch Linux x86_64~
- off :: ~Arch Linux~
#+begin_src sh
os_arch="off"
#+end_src
**** Packages
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-OS-Packages-f836a58d
:END:
It is possible to show or hide Package Manager names.
- Default :: ~'tiny'~
- Values :: ~'on'~ / ~'tiny'~ / ~'off'~
- Flag :: ~--package_managers~
- Example ::
- on :: ~'998 (pacman), 8 (flatpak), 4 (snap)'~
- tiny :: ~'908 (pacman, flatpak, snap)'~
- off :: ~'908'~
#+BEGIN_SRC sh
package_managers="on"
#+END_SRC
It is possible to show or hide Package Manager names.
- Default :: ~'tiny'~
- Values :: ~'on'~ / ~'tiny'~ / ~'off'~
- Flag :: ~--package_managers~
- Example ::
- on :: ~'998 (pacman), 8 (flatpak), 4 (snap)'~
- tiny :: ~'908 (pacman, flatpak, snap)'~
- off :: ~'908'~
#+BEGIN_SRC sh
package_managers="on"
#+END_SRC
**** Shell
:PROPERTIES:
@ -195,142 +177,136 @@
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-Shell-Shell_path-9eda636d
:END:
This allows to show either the path of the users shell, or simply its
name.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--shell_path~
- Examples ::
- on :: ~/bin/bash~
- off :: ~bash~
#+begin_src sh
shell_path="off"
#+end_src
This allows to show either the path of the users shell, or simply its name.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--shell_path~
- Examples ::
- on :: ~/bin/bash~
- off :: ~bash~
+begin_src sh
shell_path="off"
+end_src
***** Shell version
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-Shell-Shell_version-03964bb3
:END:
This allows to show the shells version in the output of ~shell~.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--shell_version~
- Examples ::
- on :: ~bash 4.4.5~
- off :: ~bash~
#+begin_src sh
shell_version="off"
#+end_src
This allows to show the shells version in the output of ~shell~.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--shell_version~
- Examples ::
- on :: ~bash 4.4.5~
- off :: ~bash~
#+begin_src sh
shell_version="off"
#+end_src
*** Uptime
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-Uptime-a7b5361a
:END:
This variable can shorten the output of the ~uptime~ function. ~on~ shortens
it a bit, while ~tiny~ shortens it greatly.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"tiny"~
- ~"off"~
- Flag :: ~--uptime_shorthand~
- Examples ::
- on :: ~2 days, 10 hours, 3 mins~
- off :: ~2 days, 10 hours, 3 minutes~
- tiny :: ~2d 10h 3m~
#+begin_src sh
uptime_shorthand="on"
#+end_src
This variable can shorten the output of the ~uptime~ function. ~on~ shortens
it a bit, while ~tiny~ shortens it greatly.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"tiny"~
- ~"off"~
- Flag :: ~--uptime_shorthand~
- Examples ::
- on :: ~2 days, 10 hours, 3 mins~
- off :: ~2 days, 10 hours, 3 minutes~
- tiny :: ~2d 10h 3m~
#+begin_src sh
uptime_shorthand="on"
#+end_src
*** IP address
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-IP_address-26df5e1d
:END:
It is possible to display the machines public IP address with the function
~ip~. The value below allows the user to change the website used to fetch
it.
- Default value :: ~"http://ident.me"~
- Value :: ~"url"~
- Flag :: ~--ip_host~
#+begin_src sh
public_ip_host="http://ident.me"
#+end_src
It is possible to display the machines public IP address with the function ~ip~. The value below allows the user to change the website used to fetch it.
- Default value :: ~"http://ident.me"~
- Value :: ~"url"~
- Flag :: ~--ip_host~
#+begin_src sh
public_ip_host="http://ident.me"
#+end_src
- Default value :: ~""~
- Values ::
- ~""~
- ~""~
- Flag :: ~""~
- Supports ::
- Examples ::
- on :: ~~
- off :: ~~
#+begin_src sh
#+end_src
- Default value :: ~""~
- Values ::
- ~""~
- ~""~
- Flag :: ~""~
- Supports ::
- Examples ::
- on :: ~~
- off :: ~~
#+begin_src sh
#+end_src
*** Theming
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-Theming-ba7f1ccd
:END:
This section will allow the user to modify what Neofetch can and cannot
display about the machines theming —by this, I mean its GTK theme, its
icons and its default font.
This section will allow the user to modify what Neofetch can and cannot display about the machines theming —by this, I mean its GTK theme, its icons and its default font.
**** Shorten output
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-Theming-Shorten_output-cbef1fa4
:END:
With this value, it is possible to shorten the output of the computers
theming.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--gtk_shorthand~
- Examples ::
- on :: ~Numix, Adwaita~
- off :: ~Numix [GTK2], Adwaita [GTK3]~
#+begin_src sh
gtk_shorthand="on"
#+end_src
With this value, it is possible to shorten the output of the computers theming.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--gtk_shorthand~
- Examples ::
- on :: ~Numix, Adwaita~
- off :: ~Numix [GTK2], Adwaita [GTK3]~
#+begin_src sh
gtk_shorthand="on"
#+end_src
**** Enable or disable theming display for GTK2
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-Theming-Enable_or_disable_theming_display_for_GTK2-f4398571
:END:
It is possible to explicitely show or hide the computers theming with GTK2
with this variable.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--gtk2~
- Examples ::
- on :: ~Numix [GTK2], Adwaita [GTK3]~
- off :: ~Adwaita [GTK3]~
#+begin_src sh
gtk2="off"
#+end_src
It is possible to explicitely show or hide the computers theming with GTK2 with this variable.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--gtk2~
- Examples ::
- on :: ~Numix [GTK2], Adwaita [GTK3]~
- off :: ~Adwaita [GTK3]~
#+begin_src sh
gtk2="off"
#+end_src
**** Enable or disable theming display for GTK3
:PROPERTIES:
:CUSTOM_ID: Information_settings-Software-Theming-Enable_or_disable_theming_display_for_GTK3-c4070e66
:END:
The same variable as above is also available for GTK3.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--gtk3~
- Examples ::
- on :: ~Numix [GTK2], Adwaita [GTK3]~
- off :: ~Numix [GTK2]~
#+begin_src sh
#+end_src
The same variable as above is also available for GTK3.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--gtk3~
- Examples ::
- on :: ~Numix [GTK2], Adwaita [GTK3]~
- off :: ~Numix [GTK2]~
#+begin_src sh
gtk3="off"
#+end_src
** Hardware
:PROPERTIES:
@ -340,190 +316,177 @@
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-CPU-eb0bcd7d
:END:
**** CPU brand
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-CPU-CPU_brand-5b25776b
:END:
With this variables, it is possible to show or hide the brand of a CPU in
the ~cpu~ output.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--cpu_brand~
- Examples ::
- on :: ~Intel i7-6500U~
- off :: ~i7-6500U~
#+begin_src sh
cpu_brand="off"
#+end_src
With this variables, it is possible to show or hide the brand of a CPU in
the ~cpu~ output.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--cpu_brand~
- Examples ::
- on :: ~Intel i7-6500U~
- off :: ~i7-6500U~
#+begin_src sh
cpu_brand="off"
#+end_src
**** CPU speed
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-CPU-CPU_speed-2bf6e5f7
:END:
With this variable, it is possible to show or hide the speed of the CPU.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--cpu_speed~
- Examples ::
- on :: ~Intel i7-6500U (4) @ 3.1GHz~
- off :: ~Intel i7-6500U (4)~
#+begin_src sh
cpu_speed="off"
#+end_src
With this variable, it is possible to show or hide the speed of the CPU.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--cpu_speed~
- Examples ::
- on :: ~Intel i7-6500U (4) @ 3.1GHz~
- off :: ~Intel i7-6500U (4)~
#+begin_src sh
cpu_speed="off"
#+end_src
**** CPU speed type
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-CPU-CPU_speed_type-a24de48f
:END:
This allows Neofetch to know what type of speed it has to fetch regarding
the machines CPU. Any file in ~/sys/devices/system/cpu/cpu0/cpufreq~ can
be used as a value.
- Default value :: ~"bios_limit"~
- Values ::
- ~"scaling_cur_freq"~
- ~"scaling_min_freq"~
- ~"scaling_max_freq"~
- ~"bios_limit"~
- Flag :: ~--speed_type~
- Supports :: Linux with ~cpufreq~
#+begin_src sh
speed_type="bios_limit"
#+end_src
This allows Neofetch to know what type of speed it has to fetch regarding the machines CPU. Any file in ~/sys/devices/system/cpu/cpu0/cpufreq~ can be used as a value.
- Default value :: ~"bios_limit"~
- Values ::
- ~"scaling_cur_freq"~
- ~"scaling_min_freq"~
- ~"scaling_max_freq"~
- ~"bios_limit"~
- Flag :: ~--speed_type~
- Supports :: Linux with ~cpufreq~
#+begin_src sh
speed_type="bios_limit"
#+end_src
**** CPU speed shorthand
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-CPU-CPU_speed_shorthand-0d15fe08
:END:
This value allows to show sorter CPU speed with less digits. This flag is
not supported in systems with CPU speed below 1GHz.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"on"~
- Flag :: ~--speed_shorthand~
- Examples ::
- on :: ~i7-6500U (4) @ 3.1GHz~
- off :: ~i7-6500U (4) @ 3.100GHz~
#+begin_src sh
speed_shorthand="on"
#+end_src
This value allows to show sorter CPU speed with less digits. This flag is not supported in systems with CPU speed below 1GHz.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"on"~
- Flag :: ~--speed_shorthand~
- Examples ::
- on :: ~i7-6500U (4) @ 3.1GHz~
- off :: ~i7-6500U (4) @ 3.100GHz~
#+begin_src sh
speed_shorthand="on"
#+end_src
**** CPU cores
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-CPU-CPU_cores-30177354
:END:
With this variable, it is possible to display the number of cores that are
available in the CPU.
- Default value :: ~"logical"~
- Values ::
- ~"logical"~
- ~"physical"~
- ~"off"~
- Flag :: ~--cpu_cores~
- Supports :: ~physical~ does not work on BSD.
- Examples ::
- logical :: ~Intel i7-6500U (4) @ 3.1GHz~ (All virtual cores)
- physical :: ~Intel i7-6500U (2) @ 3.1GHz~ (All physical cores)
- off :: ~Intel i7-6500U @ 3.1GHz~
#+begin_src sh
cpu_cores="off"
#+end_src
With this variable, it is possible to display the number of cores that are available in the CPU.
- Default value :: ~"logical"~
- Values ::
- ~"logical"~
- ~"physical"~
- ~"off"~
- Flag :: ~--cpu_cores~
- Supports :: ~physical~ does not work on BSD.
- Examples ::
- logical :: ~Intel i7-6500U (4) @ 3.1GHz~ (All virtual cores)
- physical :: ~Intel i7-6500U (2) @ 3.1GHz~ (All physical cores)
- off :: ~Intel i7-6500U @ 3.1GHz~
#+begin_src sh
cpu_cores="off"
#+end_src
**** CPU temperature
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-CPU-CPU_temperature-a22e522c
:END:
This variable allows the user to hide or show the CPUs temperature, and if
shown, the user can display it in Celcius or Farenheit degrees. For FreeBSD
and NetBSD-based systems, youll need to enable the ~coretemp~ kernel
module. This only supports newer Intel processors.
- Default value :: ~"off"~
- Values ::
- ~"C"~
- ~"F"~
- ~"off"~
- Flag :: ~--cpu_temp~
- Supports :: Linux, BSD
- Examples ::
- C :: ~Intel i7-6500U (4) @ 3.1GHz [27.2°C]~
- F :: ~Intel i7-6500U (4) @ 3.1GHz [82.0°F]~
- off :: ~Intel i7-6500U (4) @ 3.1GHz~
#+begin_src sh
cpu_temp="off"
#+end_src
This variable allows the user to hide or show the CPUs temperature, and if shown, the user can display it in Celcius or Farenheit degrees. For FreeBSD and NetBSD-based systems, youll need to enable the ~coretemp~ kernel module. This only supports newer Intel processors.
- Default value :: ~"off"~
- Values ::
- ~"C"~
- ~"F"~
- ~"off"~
- Flag :: ~--cpu_temp~
- Supports :: Linux, BSD
- Examples ::
- C :: ~Intel i7-6500U (4) @ 3.1GHz [27.2°C]~
- F :: ~Intel i7-6500U (4) @ 3.1GHz [82.0°F]~
- off :: ~Intel i7-6500U (4) @ 3.1GHz~
#+begin_src sh
cpu_temp="off"
#+end_src
*** GPU
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-GPU-2c842575
:END:
The function responsible for displaying information regarding the GPUs is
~gpu~. It will try to list all available GPUs and display what it knows
about them.
The function responsible for displaying information regarding the GPUs is ~gpu~. It will try to list all available GPUs and display what it knows about them.
**** GPU brand
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-GPU-GPU_brand-6e2da615
:END:
This value allows the user to hide or show the brand of their GPU in the
output of ~gpu~.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--gpu_brand~
- Supports ::
- Examples ::
- on :: ~AMD HD 7950~
- off :: ~HD 7950~
#+begin_src sh
gpu_brand="off"
#+end_src
This value allows the user to hide or show the brand of their GPU in the output of ~gpu~.
- Default value :: ~"on"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--gpu_brand~
- Supports ::
- Examples ::
- on :: ~AMD HD 7950~
- off :: ~HD 7950~
#+begin_src sh
gpu_brand="off"
#+end_src
**** Which GPU to display
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-GPU-Which_GPU_to_display-f40d3aac
:END:
This allows the user to choose which GPU appears in the output of the
function ~gpu~.
- Default value :: ~"all"~
- Values ::
- ~"all"~
- ~"dedicated"~
- ~"integrated"~
- Flag :: ~--gpu_type~
- Supports :: Linux
- Examples ::
- all ::
#+BEGIN_SRC text
GPU1: AMD HD 7950
GPU2: Intel Integrated Graphics
#+END_SRC
- dedicated :: ~GPU1: AMD HD 7950~
- integrated :: ~GPU1: Intel Integrated Graphics~
#+begin_src sh
gpu_type="all"
#+end_src
This allows the user to choose which GPU appears in the output of the function ~gpu~.
- Default value :: ~"all"~
- Values ::
- ~"all"~
- ~"dedicated"~
- ~"integrated"~
- Flag :: ~--gpu_type~
- Supports :: Linux
- Examples ::
- all ::
#+BEGIN_SRC text
GPU1: AMD HD 7950
GPU2: Intel Integrated Graphics
#+END_SRC
- dedicated :: ~GPU1: AMD HD 7950~
- integrated :: ~GPU1: Intel Integrated Graphics~
#+begin_src sh
gpu_type="all"
#+end_src
*** Resolution
:PROPERTIES:
:CUSTOM_ID: Information_settings-Hardware-Resolution-b768f865
:END:
This will try to list all the connected screens and display their resolution
individually. It is possible to display the refresh rate or to hide it.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--refresh_rate~
- Supports :: Does not work on Windows
- Examples ::
- on :: ~1920x1080 @ 60Hz~
- off :: ~1920x1080~
#+begin_src sh
refresh_rate="off"
#+end_src
This will try to list all the connected screens and display their resolution individually. It is possible to display the refresh rate or to hide it.
- Default value :: ~"off"~
- Values ::
- ~"on"~
- ~"off"~
- Flag :: ~--refresh_rate~
- Supports :: Does not work on Windows
- Examples ::
- on :: ~1920x1080 @ 60Hz~
- off :: ~1920x1080~
#+begin_src sh
refresh_rate="off"
#+end_src

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -10,117 +10,99 @@
:PROPERTIES:
:CUSTOM_ID: Introduction-465e99fe
:END:
The ~.rustfmt.toml~ file located in the ~$HOME~ directory is a global
configuration file for Rusts code formatters, such as ~rustfmt~. In this
file, you can find how my Rust code is always formatted.
The ~.rustfmt.toml~ file located in the ~$HOME~ directory is a global configuration file for Rusts code formatters, such as ~rustfmt~. In this file, you can find how my Rust code is always formatted.
* General settings
:PROPERTIES:
:CUSTOM_ID: General_settings-7f5cb2f6
:END:
First, we are using the 2018 edition of Rust.
#+BEGIN_SRC toml
edition = "2018"
#+END_SRC
Put single-expression functions on a single line.
#+BEGIN_SRC toml
fn_single_line = true
#+END_SRC
Format string literals where necessary.
#+BEGIN_SRC toml
format_strings = true
#+END_SRC
Maximum width of each line
#+BEGIN_SRC toml
max_width = 80
#+END_SRC
Merge multiple imports into a single nested import.
#+BEGIN_SRC toml
merge_imports = true
#+END_SRC
First, we are using the 2018 edition of Rust.
#+BEGIN_SRC toml
edition = "2018"
#+END_SRC
Put single-expression functions on a single line.
#+BEGIN_SRC toml
fn_single_line = true
#+END_SRC
Format string literals where necessary.
#+BEGIN_SRC toml
format_strings = true
#+END_SRC
Maximum width of each line
#+BEGIN_SRC toml
max_width = 80
#+END_SRC
Merge multiple imports into a single nested import.
#+BEGIN_SRC toml
merge_imports = true
#+END_SRC
* Structs and Enums
:PROPERTIES:
:CUSTOM_ID: Structs_and_Enums-6a2a856d
:END:
The maximum length of enum variant having discriminant, that gets vertically
aligned with others. Variants without discriminants would be ignored for the
purpose of alignment.
The maximum length of enum variant having discriminant, that gets vertically aligned with others. Variants without discriminants would be ignored for the purpose of alignment.
Note that this is not how much whitespace is inserted, but instead the longest
variant name that doesn't get ignored when aligning.
#+BEGIN_SRC toml
enum_discrim_align_threshold = 20
#+END_SRC
The maximum diff of width between struct fields to be aligned with each other.
#+BEGIN_SRC toml
struct_field_align_threshold = 20
#+END_SRC
Reorder impl items. ~type~ and ~const~ are put first, then macros and methods.
#+BEGIN_SRC toml
reorder_impl_items = true
#+END_SRC
Note that this is not how much whitespace is inserted, but instead the longest variant name that doesn't get ignored when aligning.
#+BEGIN_SRC toml
enum_discrim_align_threshold = 20
#+END_SRC
The maximum diff of width between struct fields to be aligned with each other.
#+BEGIN_SRC toml
struct_field_align_threshold = 20
#+END_SRC
Reorder impl items. ~type~ and ~const~ are put first, then macros and methods.
#+BEGIN_SRC toml
reorder_impl_items = true
#+END_SRC
* Comments
:PROPERTIES:
:CUSTOM_ID: Comments-b1904bb0
:END:
Convert ~/* */~ comments to ~//~ comments where possible.
#+BEGIN_SRC toml
normalize_comments = true
#+END_SRC
Break comments to fit on the line.
#+BEGIN_SRC toml
wrap_comments = true
#+END_SRC
Report ~FIXME~ items in comments.
#+BEGIN_SRC toml
report_fixme = "Always"
#+END_SRC
Report ~TODO~ items in comments.
#+BEGIN_SRC toml
todo = "Always"
#+END_SRC
Convert ~/* */~ comments to ~//~ comments where possible.
#+BEGIN_SRC toml
normalize_comments = true
#+END_SRC
Break comments to fit on the line.
#+BEGIN_SRC toml
wrap_comments = true
#+END_SRC
Report ~FIXME~ items in comments.
#+BEGIN_SRC toml
report_fixme = "Always"
#+END_SRC
Report ~TODO~ items in comments.
#+BEGIN_SRC toml
todo = "Always"
#+END_SRC
* Documentation
:PROPERTIES:
:CUSTOM_ID: Documentation-0c7981c7
:END:
Format code snippet included in doc comments.
#+BEGIN_SRC toml
format_code_in_doc_comments = true
#+END_SRC
Convert ~#![doc]~ and ~#[doc]~ attributes to ~//!~ and ~///~ doc comments.
#+BEGIN_SRC toml
normalize_doc_attributes = true
#+END_SRC
Format code snippet included in doc comments.
#+BEGIN_SRC toml
format_code_in_doc_comments = true
#+END_SRC
Convert ~#![doc]~ and ~#[doc]~ attributes to ~//!~ and ~///~ doc comments.
#+BEGIN_SRC toml
normalize_doc_attributes = true
#+END_SRC
* Whitespace
:PROPERTIES:
:CUSTOM_ID: Whitespace-e8792b44
:END:
Use tab characters for indentation, spaces for alignment.
#+BEGIN_SRC toml
hard_tabs = false
#+END_SRC
Number of spaces per tab.
#+BEGIN_SRC toml
tab_spaces = 4
#+END_SRC
I want newlines to always be Unix style.
#+BEGIN_SRC toml
newline_style = "Unix"
#+END_SRC
Use tab characters for indentation, spaces for alignment.
#+BEGIN_SRC toml
hard_tabs = false
#+END_SRC
Number of spaces per tab.
#+BEGIN_SRC toml
tab_spaces = 4
#+END_SRC
I want newlines to always be Unix style.
#+BEGIN_SRC toml
newline_style = "Unix"
#+END_SRC

View File

@ -10,396 +10,334 @@
:PROPERTIES:
:CUSTOM_ID: Presentation-0b37c6c0
:END:
I dont really use tmux often, but I certainly do like a nice presentation and
useful features, hence this configuration. This config file is inspired by
gpakoszs tmux configuration repo you can find [[https://github.com/gpakosz/.tmux][here]].
I dont really use tmux often, but I certainly do like a nice presentation and useful features, hence this configuration. This config file is inspired by gpakoszs tmux configuration repo you can find [[https://github.com/gpakosz/.tmux][here]].
* Windows and pane creation
:PROPERTIES:
:CUSTOM_ID: Windows_and_pane_creation-66275518
:END:
Whether if a new *window* will retain the current path. Possible values are:
- true
- false (default)
#+BEGIN_SRC conf-unix
tmux_conf_new_window_retain_current_path=true
#+END_SRC
Whether if a new *pane* should retain the current path. Possible values are:
- true (default)
- false
#+BEGIN_SRC conf-unix
tmux_conf_new_window_retain_current_path=true
#+END_SRC
Whether or not tmux should attempt to reconnect to the current ssh session.
This is still experimental. Possible values are:
- true
- false (default)
#+BEGIN_SRC conf-unix
tmux_conf_new_pane_reconnect_ssh=true
#+END_SRC
Whether tmux should prompt for new session name when creating a new one.
Possible values are:
- true
- false (default)
#+BEGIN_SRC conf-unix
tmux_conf_new_session_prompt=false
#+END_SRC
Whether if a new *window* will retain the current path. Possible values are:
- ~true~
- ~false~ (default)
#+BEGIN_SRC conf-unix
tmux_conf_new_window_retain_current_path=true
#+END_SRC
Whether if a new *pane* should retain the current path. Possible values are:
- ~true~ (default)
- ~false~
#+BEGIN_SRC conf-unix
tmux_conf_new_window_retain_current_path=true
#+END_SRC
Whether or not tmux should attempt to reconnect to the current ssh session. This is still experimental. Possible values are:
- ~true~
- ~false~ (default)
#+BEGIN_SRC conf-unix
tmux_conf_new_pane_reconnect_ssh=true
#+END_SRC
Whether tmux should prompt for new session name when creating a new one. Possible values are:
- ~true~
- ~false~ (default)
#+BEGIN_SRC conf-unix
tmux_conf_new_session_prompt=false
#+END_SRC
* Display
:PROPERTIES:
:CUSTOM_ID: Display-d5ae1908
:END:
Whether to activate RGB 24-bit color support (only available in tmux >= 2.2).
Possible values are:
- true
- false (default)
#+BEGIN_SRC conf-unix
tmux_conf_theme_24b_colour=false
#+END_SRC
These variables are for chosing the window style. I use the default one.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_fg='default'
tmux_conf_theme_window_bg='default'
#+END_SRC
Whether the focused pane should be highlighted (only available in tmux >=
2.1). Possible values are:
- true
- false (default)
#+BEGIN_SRC conf-unix
tmux_conf_theme_highlight_focused_pane=false
#+END_SRC
Set the terminal title. Built-in variables are:
- =#{circled_window_index}=
- =#{circled_session_name}=
- =#{hostname}=
- =#{hostname_ssh}=
- =#{username}=
- =#{username_ssh}=
#+BEGIN_SRC conf-unix
tmux_conf_theme_terminal_title='#h ❐ #S ● #I #W'
#+END_SRC
These variables set the left/right separators between sections. With the
current values, you dont need to install Powerline, but only fonts patched
with Powerline symbols or the standalone PowerlineSymbols.otf font.
#+BEGIN_SRC conf-unix
tmux_conf_theme_left_separator_main='\uE0B0'
tmux_conf_theme_left_separator_sub='\uE0B1'
tmux_conf_theme_right_separator_main='\uE0B2'
tmux_conf_theme_right_separator_sub='\uE0B3'
#+END_SRC
Whether to activate RGB 24-bit color support (only available in tmux >= 2.2). Possible values are:
- ~true~
- ~false~ (default)
#+BEGIN_SRC conf-unix
tmux_conf_theme_24b_colour=false
#+END_SRC
These variables are for chosing the window style. I use the default one.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_fg='default'
tmux_conf_theme_window_bg='default'
#+END_SRC
Whether the focused pane should be highlighted (only available in tmux >= 2.1). Possible values are:
- ~true~
- ~false~ (default)
#+BEGIN_SRC conf-unix
tmux_conf_theme_highlight_focused_pane=false
#+END_SRC
Set the terminal title. Built-in variables are:
- =#{circled_window_index}=
- =#{circled_session_name}=
- =#{hostname}=
- =#{hostname_ssh}=
- =#{username}=
- =#{username_ssh}=
#+BEGIN_SRC conf-unix
tmux_conf_theme_terminal_title='#h ❐ #S ● #I #W'
#+END_SRC
These variables set the left/right separators between sections. With the current values, you dont need to install Powerline, but only fonts patched with Powerline symbols or the standalone PowerlineSymbols.otf font.
#+BEGIN_SRC conf-unix
tmux_conf_theme_left_separator_main='\uE0B0'
tmux_conf_theme_left_separator_sub='\uE0B1'
tmux_conf_theme_right_separator_main='\uE0B2'
tmux_conf_theme_right_separator_sub='\uE0B3'
#+END_SRC
** Colors and style
:PROPERTIES:
:CUSTOM_ID: Display-Colors_and_style-0994a014
:END:
Colors displayed in tmux can be chosen thanks to the following variables. Any
color should be formatted as a hexadecimal RGB value preceded by a pound sign
=#= (e.g. =#00afff= for light blue) or =default= to let our terminal set it
for us.
Colors displayed in tmux can be chosen thanks to the following variables. Any color should be formatted as a hexadecimal RGB value preceded by a pound sign =#= (e.g. =#00afff= for light blue) or =default= to let our terminal set it for us.
Choose the style of the pane borders. Possible values are:
- thin (default)
- fat
#+BEGIN_SRC conf-unix
tmux_conf_theme_pane_border_style=thin
#+END_SRC
Declare what the colors of the focused pane should be. The first variable
specifies the foreground color, the other the background color.
#+BEGIN_SRC conf-unix
tmux_conf_theme_focused_pane_fg='default'
tmux_conf_theme_focused_pane_bg='#0087d7'
#+END_SRC
Here you can set the colors of the pane borders.
#+BEGIN_SRC conf-unix
tmux_conf_theme_pane_border='#444444'
tmux_conf_theme_pane_active_border='#00afff'
#+END_SRC
With these variables, you can set the colors for the pane indicators.
#+BEGIN_SRC conf-unix
tmux_conf_theme_pane_indicator='#00afff'
tmux_conf_theme_pane_active_indicator='#00afff'
#+END_SRC
These variables set the colors and the style of the status line.
#+BEGIN_SRC conf-unix
tmux_conf_theme_message_fg='#000000'
tmux_conf_theme_message_bg='#ffff00'
tmux_conf_theme_message_attr='bold'
#+END_SRC
Same as above for the status line command style.
#+BEGIN_SRC conf-unix
tmux_conf_theme_message_command_fg='#ffff00'
tmux_conf_theme_message_command_bg='#000000'
tmux_conf_theme_message_command_attr='bold'
#+END_SRC
These variables set the style of the window modes.
#+BEGIN_SRC conf-unix
tmux_conf_theme_mode_fg='#000000'
tmux_conf_theme_mode_bg='#ffff00'
tmux_conf_theme_mode_attr='bold'
#+END_SRC
Set the style of the status line.
#+BEGIN_SRC conf-unix
tmux_conf_theme_status_fg='#8a8a8a'
tmux_conf_theme_status_bg='#080808'
tmux_conf_theme_status_attr='none'
#+END_SRC
Choose the style of the pane borders. Possible values are:
- ~thin~ (default)
- ~fat~
#+BEGIN_SRC conf-unix
tmux_conf_theme_pane_border_style=thin
#+END_SRC
Declare what the colors of the focused pane should be. The first variable specifies the foreground color, the other the background color.
#+BEGIN_SRC conf-unix
tmux_conf_theme_focused_pane_fg='default'
tmux_conf_theme_focused_pane_bg='#0087d7'
#+END_SRC
Here you can set the colors of the pane borders.
#+BEGIN_SRC conf-unix
tmux_conf_theme_pane_border='#444444'
tmux_conf_theme_pane_active_border='#00afff'
#+END_SRC
With these variables, you can set the colors for the pane indicators.
#+BEGIN_SRC conf-unix
tmux_conf_theme_pane_indicator='#00afff'
tmux_conf_theme_pane_active_indicator='#00afff'
#+END_SRC
These variables set the colors and the style of the status line.
#+BEGIN_SRC conf-unix
tmux_conf_theme_message_fg='#000000'
tmux_conf_theme_message_bg='#ffff00'
tmux_conf_theme_message_attr='bold'
#+END_SRC
Same as above for the status line command style.
#+BEGIN_SRC conf-unix
tmux_conf_theme_message_command_fg='#ffff00'
tmux_conf_theme_message_command_bg='#000000'
tmux_conf_theme_message_command_attr='bold'
#+END_SRC
These variables set the style of the window modes.
#+BEGIN_SRC conf-unix
tmux_conf_theme_mode_fg='#000000'
tmux_conf_theme_mode_bg='#ffff00'
tmux_conf_theme_mode_attr='bold'
#+END_SRC
Set the style of the status line.
#+BEGIN_SRC conf-unix
tmux_conf_theme_status_fg='#8a8a8a'
tmux_conf_theme_status_bg='#080808'
tmux_conf_theme_status_attr='none'
#+END_SRC
** Window status bar
:PROPERTIES:
:CUSTOM_ID: Display-Window_status_bar-dff37ae7
:END:
The following variables are to set the windows status style and format.
The following variables are to set the windows status style and format.
Sets the colors and style of the window status.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_fg='#8a8a8a'
tmux_conf_theme_window_status_bg='#080808'
tmux_conf_theme_window_status_attr='none'
#+END_SRC
Sets the format of the window status. Built-in variables are:
- =#{circled_window_index}=
- =#{circled_session_name}=
- =#{hostname}=
- =#{hostname_ssh}=
- =#{username}=
- =#{username_ssh}=
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_format='#I #W'
#+END_SRC
Sets the colors and style of the current window status.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_current_fg='#000000'
tmux_conf_theme_window_status_current_bg='#00afff'
tmux_conf_theme_window_status_current_attr='bold'
#+END_SRC
Sets the format of the currentwindow status. Built-in variables are:
- =#{circled_window_index}=
- =#{circled_session_name}=
- =#{hostname}=
- =#{hostname_ssh}=
- =#{username}=
- =#{username_ssh}=
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_current_format='#I #W'
#+END_SRC
Sets the window activity status style.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_activity_fg='default'
tmux_conf_theme_window_status_activity_bg='default'
tmux_conf_theme_window_status_activity_attr='underscore'
#+END_SRC
Sets the window bell status style.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_bell_fg='#ffff00'
tmux_conf_theme_window_status_bell_bg='default'
tmux_conf_theme_window_status_bell_attr='blink,bold'
#+END_SRC
Sets the window last status style.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_last_fg='#00afff'
tmux_conf_theme_window_status_last_bg='default'
tmux_conf_theme_window_status_last_attr='none'
#+END_SRC
Sets the left and right content of the status bar of tmux. Sections should be
separated with =|=, subsections with =,=. The built-in values are:
- =#{battery_bar}=
- =#{battery_hbar}=
- =#{battery_percentage}=
- =#{battery_status}=
- =#{battery_vbar}=
- =#{circled_session_name}=
- =#{hostname_ssh}=
- =#{hostname}=
- =#{loadavg}=
- =#{pairing}=
- =#{prefix}=
- =#{root}=
- =#{synchronized}=
- =#{uptime_y}=
- =#{uptime_d}= (modulo 365 when =#{uptime_y}= is used)
- =#{uptime_h}=
- =#{uptime_m}=
- =#{uptime_s}=
- =#{username}=
- =#{username_ssh}=
#+BEGIN_SRC conf-unix
tmux_conf_theme_status_left=' ❐ #S | ↑#{?uptime_y, #{uptime_y}y,}#{?uptime_d, #{uptime_d}d,}#{?uptime_h, #{uptime_h}h,}#{?uptime_m, #{uptime_m}m,} '
tmux_conf_theme_status_right='#{prefix}#{pairing}#{synchronized} #{?battery_status, #{battery_status},}#{?battery_bar, #{battery_bar},}#{?battery_percentage, #{battery_percentage},} , %R , %d %b | #{username}#{root} | #{hostname} '
#+END_SRC
Sets the left status style and colors.
#+BEGIN_SRC conf-unix
tmux_conf_theme_status_left_fg='#000000,#e4e4e4,#e4e4e4'
tmux_conf_theme_status_left_bg='#ffff00,#ff00af,#00afff'
tmux_conf_theme_status_left_attr='bold,none,none'
#+END_SRC
Sets the right status style and colors.
#+BEGIN_SRC conf-unix
tmux_conf_theme_status_right_fg='#8a8a8a,#e4e4e4,#000000'
tmux_conf_theme_status_right_bg='#080808,#d70000,#e4e4e4'
tmux_conf_theme_status_right_attr='none,none,bold'
#+END_SRC
Set the pairing indicator, its style and its attribute.
#+BEGIN_SRC conf-unix
tmux_conf_theme_pairing='👓 ' # U+1F453
tmux_conf_theme_pairing_fg='none'
tmux_conf_theme_pairing_bg='none'
tmux_conf_theme_pairing_attr='none'
#+END_SRC
Set the pairing indicator, its style and its attribute.
#+BEGIN_SRC conf-unix
# prefix indicator
tmux_conf_theme_prefix='⌨ ' # U+2328
tmux_conf_theme_prefix_fg='none'
tmux_conf_theme_prefix_bg='none'
tmux_conf_theme_prefix_attr='none'
#+END_SRC
Set the root indicator, its style and its attribute.
#+BEGIN_SRC conf-unix
tmux_conf_theme_root='!'
tmux_conf_theme_root_fg='none'
tmux_conf_theme_root_bg='none'
tmux_conf_theme_root_attr='bold,blink'
#+END_SRC
Set the synchronized indicator, its style and its attribute.
#+BEGIN_SRC conf-unix
tmux_conf_theme_synchronized='🔒' # U+1F512
tmux_conf_theme_synchronized_fg='none'
tmux_conf_theme_synchronized_bg='none'
tmux_conf_theme_synchronized_attr='none'
#+END_SRC
Set the battery bar symbols.
#+BEGIN_SRC conf-unix
tmux_conf_battery_bar_symbol_full='◼'
tmux_conf_battery_bar_symbol_empty='◻'
#+END_SRC
Set the battery bar length in terms of amount of symbols. Possible values
are:
- =auto=
- an integer number, e.g. 5
#+BEGIN_SRC conf-unix
tmux_conf_battery_bar_length='auto'
#+END_SRC
Set the battery bar palette. Possible values are:
- =gradient= (default)
- =heat=
- =color_full_fg,color_empty_fg,color_bg= with each being an hexadecimal RGB
value preceded by a pound symbol =#=.
#+BEGIN_SRC conf-unix
tmux_conf_battery_bar_palette='gradient'
#tmux_conf_battery_bar_palette='#d70000,#e4e4e4,#000000'
#+END_SRC
Set the hbar palette. Possible values are:
- =gradient= (default)
- =heat=
- =color_full_fg,color_empty_fg,color_bg= with each being an hexadecimal RGB
value preceded by a pound symbol =#=.
#+BEGIN_SRC conf-unix
tmux_conf_battery_hbar_palette='gradient'
#+END_SRC
Set the vbar palette. Possible values are:
- =gradient= (default)
- =heat=
- =color_full_fg,color_empty_fg,color_bg= with each being an hexadecimal RGB
value preceded by a pound symbol =#=.
#+BEGIN_SRC conf-unix
tmux_conf_battery_vbar_palette='gradient'
#+END_SRC
Set symbols used to indicate whether the battery is charging or discharging.
#+BEGIN_SRC conf-unix
tmux_conf_battery_status_charging='⚡ ' # U+26A1
tmux_conf_battery_status_discharging='🔋 ' # U+1F50B
# tmux_conf_battery_status_charging='↑' # U+2191
# tmux_conf_battery_status_discharging='↓' # U+2193
#tmux_conf_battery_status_charging='🔌 ' # U+1F50C
#+END_SRC
Set the clock style. If it is displayed on the right side of the status bar,
it might be better to use =%I:%M %p= rather than =%R= in
=tmux_conf_theme_status_right=.
#+BEGIN_SRC conf-unix
tmux_conf_theme_clock_colour='#00afff'
tmux_conf_theme_clock_style='24'
#+END_SRC
Sets the colors and style of the window status.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_fg='#8a8a8a'
tmux_conf_theme_window_status_bg='#080808'
tmux_conf_theme_window_status_attr='none'
#+END_SRC
Sets the format of the window status. Built-in variables are:
- =#{circled_window_index}=
- =#{circled_session_name}=
- =#{hostname}=
- =#{hostname_ssh}=
- =#{username}=
- =#{username_ssh}=
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_format='#I #W'
#+END_SRC
Sets the colors and style of the current window status.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_current_fg='#000000'
tmux_conf_theme_window_status_current_bg='#00afff'
tmux_conf_theme_window_status_current_attr='bold'
#+END_SRC
Sets the format of the currentwindow status. Built-in variables are:
- =#{circled_window_index}=
- =#{circled_session_name}=
- =#{hostname}=
- =#{hostname_ssh}=
- =#{username}=
- =#{username_ssh}=
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_current_format='#I #W'
#+END_SRC
Sets the window activity status style.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_activity_fg='default'
tmux_conf_theme_window_status_activity_bg='default'
tmux_conf_theme_window_status_activity_attr='underscore'
#+END_SRC
Sets the window bell status style.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_bell_fg='#ffff00'
tmux_conf_theme_window_status_bell_bg='default'
tmux_conf_theme_window_status_bell_attr='blink,bold'
#+END_SRC
Sets the window last status style.
#+BEGIN_SRC conf-unix
tmux_conf_theme_window_status_last_fg='#00afff'
tmux_conf_theme_window_status_last_bg='default'
tmux_conf_theme_window_status_last_attr='none'
#+END_SRC
Sets the left and right content of the status bar of tmux. Sections should be separated with =|=, subsections with =,=. The built-in values are:
- =#{battery_bar}=
- =#{battery_hbar}=
- =#{battery_percentage}=
- =#{battery_status}=
- =#{battery_vbar}=
- =#{circled_session_name}=
- =#{hostname_ssh}=
- =#{hostname}=
- =#{loadavg}=
- =#{pairing}=
- =#{prefix}=
- =#{root}=
- =#{synchronized}=
- =#{uptime_y}=
- =#{uptime_d}= (modulo 365 when =#{uptime_y}= is used)
- =#{uptime_h}=
- =#{uptime_m}=
- =#{uptime_s}=
- =#{username}=
- =#{username_ssh}=
#+BEGIN_SRC conf-unix
tmux_conf_theme_status_left=' ❐ #S | ↑#{?uptime_y, #{uptime_y}y,}#{?uptime_d, #{uptime_d}d,}#{?uptime_h, #{uptime_h}h,}#{?uptime_m, #{uptime_m}m,} '
tmux_conf_theme_status_right='#{prefix}#{pairing}#{synchronized} #{?battery_status, #{battery_status},}#{?battery_bar, #{battery_bar},}#{?battery_percentage, #{battery_percentage},} , %R , %d %b | #{username}#{root} | #{hostname} '
#+END_SRC
Sets the left status style and colors.
#+BEGIN_SRC conf-unix
tmux_conf_theme_status_left_fg='#000000,#e4e4e4,#e4e4e4'
tmux_conf_theme_status_left_bg='#ffff00,#ff00af,#00afff'
tmux_conf_theme_status_left_attr='bold,none,none'
#+END_SRC
Sets the right status style and colors.
#+BEGIN_SRC conf-unix
tmux_conf_theme_status_right_fg='#8a8a8a,#e4e4e4,#000000'
tmux_conf_theme_status_right_bg='#080808,#d70000,#e4e4e4'
tmux_conf_theme_status_right_attr='none,none,bold'
#+END_SRC
Set the pairing indicator, its style and its attribute.
#+BEGIN_SRC conf-unix
tmux_conf_theme_pairing='👓 ' # U+1F453
tmux_conf_theme_pairing_fg='none'
tmux_conf_theme_pairing_bg='none'
tmux_conf_theme_pairing_attr='none'
#+END_SRC
Set the pairing indicator, its style and its attribute.
#+BEGIN_SRC conf-unix
# prefix indicator
tmux_conf_theme_prefix='⌨ ' # U+2328
tmux_conf_theme_prefix_fg='none'
tmux_conf_theme_prefix_bg='none'
tmux_conf_theme_prefix_attr='none'
#+END_SRC
Set the root indicator, its style and its attribute.
#+BEGIN_SRC conf-unix
tmux_conf_theme_root='!'
tmux_conf_theme_root_fg='none'
tmux_conf_theme_root_bg='none'
tmux_conf_theme_root_attr='bold,blink'
#+END_SRC
Set the synchronized indicator, its style and its attribute.
#+BEGIN_SRC conf-unix
tmux_conf_theme_synchronized='🔒' # U+1F512
tmux_conf_theme_synchronized_fg='none'
tmux_conf_theme_synchronized_bg='none'
tmux_conf_theme_synchronized_attr='none'
#+END_SRC
Set the battery bar symbols.
#+BEGIN_SRC conf-unix
tmux_conf_battery_bar_symbol_full='◼'
tmux_conf_battery_bar_symbol_empty='◻'
#+END_SRC
Set the battery bar length in terms of amount of symbols. Possible values are:
- =auto=
- an integer number, e.g. 5
#+BEGIN_SRC conf-unix
tmux_conf_battery_bar_length='auto'
#+END_SRC
Set the battery bar palette. Possible values are:
- =gradient= (default)
- =heat=
- =color_full_fg,color_empty_fg,color_bg= with each being an hexadecimal RGB value preceded by a pound symbol =#=.
#+BEGIN_SRC conf-unix
tmux_conf_battery_bar_palette='gradient'
#tmux_conf_battery_bar_palette='#d70000,#e4e4e4,#000000'
#+END_SRC
Set the hbar palette. Possible values are:
- =gradient= (default)
- =heat=
- =color_full_fg,color_empty_fg,color_bg= with each being an hexadecimal RGB value preceded by a pound symbol =#=.
#+BEGIN_SRC conf-unix
tmux_conf_battery_hbar_palette='gradient'
#+END_SRC
Set the vbar palette. Possible values are:
- =gradient= (default)
- =heat=
- =color_full_fg,color_empty_fg,color_bg= with each being an hexadecimal RGB value preceded by a pound symbol =#=.
#+BEGIN_SRC conf-unix
tmux_conf_battery_vbar_palette='gradient'
#+END_SRC
Set symbols used to indicate whether the battery is charging or discharging.
#+BEGIN_SRC conf-unix
tmux_conf_battery_status_charging='⚡ ' # U+26A1
tmux_conf_battery_status_discharging='🔋 ' # U+1F50B
# tmux_conf_battery_status_charging='↑' # U+2191
# tmux_conf_battery_status_discharging='↓' # U+2193
#tmux_conf_battery_status_charging='🔌 ' # U+1F50C
#+END_SRC
Set the clock style. If it is displayed on the right side of the status bar, it might be better to use =%I:%M %p= rather than =%R= in =tmux_conf_theme_status_right=.
#+BEGIN_SRC conf-unix
tmux_conf_theme_clock_colour='#00afff'
tmux_conf_theme_clock_style='24'
#+END_SRC
* Clipboard
:PROPERTIES:
:CUSTOM_ID: Clipboard-66d0d03a
:END:
Whether if in copy mode, copying the selection also copies to the OS
clipboard. Possible values are:
- true
- false (default)
#+BEGIN_SRC conf-unix
tmux_conf_copy_to_os_clipboard=false
#+END_SRC
Whether if in copy mode, copying the selection also copies to the OS clipboard. Possible values are:
- ~true~
- ~false~ (default)
#+BEGIN_SRC conf-unix
tmux_conf_copy_to_os_clipboard=false
#+END_SRC
* User customizations
:PROPERTIES:
:CUSTOM_ID: User_customizations-c913b5d7
:END:
Here we can override or undo some setting from settings from tmux. First, we
can increase the history size.
#+BEGIN_SRC conf-unix
set -g history-limit 10000
#+END_SRC
We can also start with mouse mode enabled. But I dont.
#+BEGIN_SRC conf-unix
#set -g mouse on
#+END_SRC
Whether or not Vi mode should be enabled. But really, we should rather export
the =VISUAL= or =EDITOR= environment variables, see the tmux manual. Although
I dont, as said in my dotfish, I prefer to use Emacs.
#+BEGIN_SRC conf-unix
#set -g status-keys vi
#set -g mode-keys vi
#+END_SRC
Replace =C-b= by =C-a= instead of using both prefixes. I personally prefer to
just use =C-b=, hence why the lines are commented.
#+BEGIN_SRC conf-unix
# set -gu prefix2
# unbind C-a
# unbind C-b
# set -g prefix C-a
# bind C-a send-prefix
#+END_SRC
Move the status line to the top.
#+BEGIN_SRC conf-unix
#set -g status-position top
#+END_SRC
Here we can override or undo some setting from settings from tmux. First, we can increase the history size.
#+BEGIN_SRC conf-unix
set -g history-limit 10000
#+END_SRC
We can also start with mouse mode enabled. But I dont.
#+BEGIN_SRC conf-unix
#set -g mouse on
#+END_SRC
Whether or not Vi mode should be enabled. But really, we should rather export the =VISUAL= or =EDITOR= environment variables, see the tmux manual. Although I dont, as said in my dotfish, I prefer to use Emacs.
#+BEGIN_SRC conf-unix
#set -g status-keys vi
#set -g mode-keys vi
#+END_SRC
Replace =C-b= by =C-a= instead of using both prefixes. I personally prefer to just use =C-b=, hence why the lines are commented.
#+BEGIN_SRC conf-unix
# set -gu prefix2
# unbind C-a
# unbind C-b
# set -g prefix C-a
# bind C-a send-prefix
#+END_SRC
Move the status line to the top.
#+BEGIN_SRC conf-unix
#set -g status-position top
#+END_SRC