Kaynağa Gözat

refactoring

systemd-xsession
ebeveyn
işleme
fd3f8235de
33 değiştirilmiş dosya ile 267 ekleme ve 272 silme
  1. +21
    -25
      defaults/main.yaml
  2. +1
    -1
      files/bin/i3-watchers
  3. +2
    -5
      files/bin/on-focus-workspace
  4. +1
    -1
      files/bin/on-space-shortcut
  5. +2
    -0
      files/bin/timer
  6. +13
    -0
      tasks/background.yaml
  7. +5
    -0
      tasks/clean.yaml
  8. +0
    -106
      tasks/eralitex.yaml
  9. +13
    -6
      tasks/i3.yaml
  10. +1
    -1
      tasks/kanboard.yaml
  11. +7
    -8
      tasks/main.yaml
  12. +1
    -1
      tasks/points.yaml
  13. +12
    -0
      tasks/rofi.yaml
  14. +1
    -1
      tasks/ssh.yaml
  15. +7
    -12
      tasks/structure.yaml
  16. +6
    -0
      tasks/vnc.yaml
  17. +24
    -0
      tasks/workspaces.yaml
  18. +23
    -1
      tasks/x11.yaml
  19. +1
    -1
      templates/Xmodmap.j2
  20. +16
    -3
      templates/Xresources.j2
  21. +52
    -41
      templates/i3.config.j2
  22. +1
    -1
      templates/i3blocks.config.j2
  23. +0
    -3
      templates/other-workspace-focus.fish.j2
  24. +0
    -23
      templates/reload.sh.j2
  25. +4
    -4
      templates/rofi.theme.j2
  26. +9
    -0
      templates/tigervnc.default.j2
  27. +4
    -4
      templates/vdesk.service.j2
  28. +0
    -4
      templates/vnc-options.fish.j2
  29. +0
    -0
      templates/workspace.focus.fish.j2
  30. +5
    -1
      templates/workspace.space.fish.j2
  31. +6
    -8
      templates/xsession.fish.j2
  32. +23
    -0
      templates/xsession.reload.fish.j2
  33. +6
    -11
      vars/main.yaml

+ 21
- 25
defaults/main.yaml Dosyayı Görüntüle

@@ -1,52 +1,48 @@
---
home_xft_dpi: 96
home_copy_pulseaudio_cookie: false
home_desktop: false
home_access_to_hosts: []
home_vnc_client_low_bandwidth: false
home_remote_workspace_config: false
home_kanboard_api_settings: false
kanboard_api_settings: "{{ lookup('file', '~/.eralitex/kanboard_api_settings.json' | from_json) }}"
kanboard_api_settings: "{{ lookup('file', '~/.kanboard_api_settings.json' | from_json) }}"
# kanboard_api_url: https://kanboard.katyx.net/jsonrpc.php
# kanboard_api_user: ka
# kanboard_api_key: xxx
home_vdesk_started_and_enabled: false

eralitex_directory: ~/.eralitex
home_profile: desktop

eralitex_profile: desktop

eralitex_terminal: urxvt
eralitex_browser: firefox
default_terminal: urxvt
default_browser: firefox

# feature flags
eralitex_with_activity: false
with_activity: false

eralitex_applications:
application_shortcuts:
a: atom
w: lowriter
c: localc
c: "{{calculator_command}}"
i: loimpress
d: lodraw
F: catfish # search
j: "{{eralitex_jupyter_console_command}}"
s: xfce4-screenshooter
l: catfish
f: "{{eralitex_file_browser_command}}" # files
m: "{{eralitex_mail_command}}"
l: catfish # search
f: "{{file_browser_command}}" # files
m: "{{mail_command}}"
r: arandr

ssh_over_tor: false

eralitex_lock_command: xset s activate
eralitex_enable_screensaver_command: /usr/local/bin/screensaver-enable
eralitex_disable_screensaver_command: /usr/local/bin/screensaver-disable
eralitex_suspend_command: systemctl suspend
eralitex_reboot_command: systemctl reboot
eralitex_poweroff_command: systemctl poweroff
session_lock_command: xset s activate
session_enable_screensaver_command: /usr/local/bin/screensaver-enable
session_disable_screensaver_command: /usr/local/bin/screensaver-disable
system_suspend_command: systemctl suspend
system_reboot_command: systemctl reboot
system_poweroff_command: systemctl poweroff

eralitex_file_browser_command: thunar
eralitex_calculator_command: "{{eralitex_jupyter_console_command}}"
eralitex_jupyter_console_command: jupyter qtconsole --no-confirm-exit
eralitex_mail_command: thunderbird
file_browser_command: thunar
calculator_command: "{{default_browser}} --new-window https://www.geogebra.org/calculator"
mail_command: thunderbird

eralitex_background_image: false
background_image: false

+ 1
- 1
files/bin/i3-watchers Dosyayı Görüntüle

@@ -2,4 +2,4 @@

set DIR (cd (dirname (status -f)); and pwd)

i3-msg -t subscribe -m '["workspace"]' | jq --raw-output --unbuffered 'select(.change == "focus").current.name' | xargs -n1 -r $DIR/on-focus-workspace &
i3-msg -t subscribe -m '["workspace"]' | jq --raw-output --unbuffered 'select(.change == "focus").current.name' | xargs -n1 -r on-focus-workspace &

+ 2
- 5
files/bin/on-focus-workspace Dosyayı Görüntüle

@@ -5,13 +5,10 @@ if count $argv
else
set ws (i3-msg -t get_workspaces | jq --raw-output '.[]|select(.focused == true).name')
end
set script ~/.eralitex/workspace-cmd/$ws.focus
set oscript ~/.eralitex/workspace-cmd/other-focus
set script ~/.workspaces/$ws.focus

if type -q $script
$script
else
if type -q $oscript
$oscript
end
i3-msg mode default
end

+ 1
- 1
files/bin/on-space-shortcut Dosyayı Görüntüle

@@ -1,7 +1,7 @@
#!/usr/bin/fish

set ws (i3-msg -t get_workspaces | jq --raw-output '.[]|select(.focused == true).name')
set script ~/.eralitex/workspace-cmd/$ws.space
set script ~/.workspaces/$ws.space

if type -q $script
$script


+ 2
- 0
files/bin/timer Dosyayı Görüntüle

@@ -3,6 +3,8 @@
switch $argv[1]
case "activity"
/opt/activity/select_activity
case "uniklinik"
/opt/activity/activity 'Arbeit:Uniklinik Köln'
case "end"
/opt/activity/activity
end

+ 13
- 0
tasks/background.yaml Dosyayı Görüntüle

@@ -0,0 +1,13 @@
---

- name: backgrounds directory
file:
path: ~/.backgrounds
state: directory
when: background_image is defined

- name: background image
copy:
src: "{{background_image}}"
dest: "{{background_image_path}}"
when: background_image is defined

+ 5
- 0
tasks/clean.yaml Dosyayı Görüntüle

@@ -12,3 +12,8 @@
file:
path: ~/.config/systemd/user/eralitex@.service
state: absent

- name: remove old eralitex directory
file:
path: ~/.eralitex
state: absent

+ 0
- 106
tasks/eralitex.yaml Dosyayı Görüntüle

@@ -1,106 +0,0 @@
---

- name: xsession scripts
template:
src: xsession.sh.j2
dest: "{{eralitex_directory}}/{{item}}/xsession"
mode: 0755
with_items: "{{ eralitex_profiles }}"

- name: session reload scripts
template:
src: reload.sh.j2
dest: "{{eralitex_directory}}/{{item}}/reload"
mode: 0755
with_items: "{{ eralitex_profiles }}"

- name: rofi themes
template:
src: rofi.theme.j2
dest: "{{eralitex_directory}}/{{item}}/rofi.theme"
mode: 0755
with_items: "{{ eralitex_profiles }}"

- name: Xmodmap
template:
src: Xmodmap.j2
dest: "{{eralitex_directory}}/Xmodmap"

- name: urxvt Xresources system config
template:
src: urxvt.Xresources.j2
dest: "{{eralitex_directory}}/urxvt.Xresources"

- name: eralitex bin directory
copy:
src: bin/
dest: "{{eralitex_directory}}/bin/"
mode: 0755

- name: link selected profile as active
file:
dest: "{{eralitex_directory}}/active-profile"
src: "{{eralitex_profile}}"
state: link


- name: link etx cli utility from users bin
file:
dest: ~/bin/etx
src: "{{eralitex_directory}}/bin/etx"
state: link

- name: link selected profile as active
file:
dest: "{{eralitex_directory}}/active-profile"
src: "{{eralitex_profile}}"
state: link

- name: background image directory
file:
path: "{{eralitex_directory}}/backgrounds"
state: directory
when: eralitex_background_image is defined

- name: background image
copy:
src: "{{eralitex_background_image}}"
dest: "{{eralitex_background_image_path}}"
when: eralitex_background_image is defined

- name: workspace-cmd directory
file:
path: "{{eralitex_directory}}/workspace-cmd"
state: directory

- name: other workspace focus script
template:
src: other-workspace-focus.fish.j2
dest: ~/.eralitex/workspace-cmd/other-focus
mode: 0755

- name: remote workspace focus scripts
template:
src: remote-workspace-focus.fish.j2
dest: ~/.eralitex/workspace-cmd/{{workspace}}.focus
mode: 0755
with_items: "{{workspaces|dict2items|json_query(\"[?value.type=='vdesk'].key\") }}"
loop_control:
loop_var: workspace
when: home_remote_workspace_config

- name: remote workspace space shortcut scripts
template:
src: remote-workspace-space.fish.j2
dest: ~/.eralitex/workspace-cmd/{{workspace}}.space
mode: 0755
with_items: "{{workspaces|dict2items|json_query(\"[?value.type=='vdesk'||value.type=='tmux'].key\") }}"
loop_control:
loop_var: workspace
when: home_remote_workspace_config

- name: vnc options
template:
src: vnc-options.fish.j2
dest: ~/.eralitex/workspace-cmd/vnc-options
mode: 0755

+ 13
- 6
tasks/i3.yaml Dosyayı Görüntüle

@@ -1,18 +1,25 @@
---

- name: i3 config directory
file:
path: ~/.config/i3
state: directory

- name: i3 config
template:
src: i3.config.j2
dest: "{{eralitex_directory}}/{{item}}/i3.config"
with_items: "{{ eralitex_profiles }}"
dest: ~/.config/i3/config

- name: check i3 config
command: i3 -c {{eralitex_directory}}/{{item}}/i3.config -C
with_items: "{{ eralitex_profiles }}"
command: i3 -c ~/.config/i3/config -C
changed_when: false

- name: i3blocks config directory
file:
path: ~/.config/i3blocks
state: directory

- name: i3blocks config
template:
src: i3blocks.config.j2
dest: "{{eralitex_directory}}/{{item}}/i3blocks.config"
with_items: "{{ eralitex_profiles }}"
dest: ~/.config/i3blocks/config

+ 1
- 1
tasks/kanboard.yaml Dosyayı Görüntüle

@@ -3,5 +3,5 @@
- name: kanboard api settings
copy:
content: "{{ kanboard_api_settings | to_json }}"
dest: ~/.eralitex/kanboard_api_settings.json
dest: ~/.kanboard_api_settings.json
when: home_kanboard_api_settings

+ 7
- 8
tasks/main.yaml Dosyayı Görüntüle

@@ -11,14 +11,13 @@

- import_tasks: points.yaml

- import_tasks: i3.yaml
when: home_desktop
- import_tasks: eralitex.yaml
when: home_desktop
- import_tasks: x11.yaml
when: home_desktop

- import_tasks: vdesk.yaml
- block:
- import_tasks: i3.yaml
- import_tasks: workspaces.yaml
- import_tasks: background.yaml
- import_tasks: rofi.yaml
- import_tasks: x11.yaml
- import_tasks: vdesk.yaml
when: home_desktop

- name: flush handlers


+ 1
- 1
tasks/points.yaml Dosyayı Görüntüle

@@ -3,5 +3,5 @@
- name: points counter
copy:
content: 0
dest: "{{eralitex_directory}}/points"
dest: ~/.points
force: no

+ 12
- 0
tasks/rofi.yaml Dosyayı Görüntüle

@@ -0,0 +1,12 @@
---

- name: rofi config directory
file:
path: ~/.config/rofi
state: directory

- name: rofi theme
template:
src: rofi.theme.j2
dest: ~/.config/rofi/theme
mode: 0755

+ 1
- 1
tasks/ssh.yaml Dosyayı Görüntüle

@@ -23,4 +23,4 @@
name: ssh-agent.service
state: started
enabled: true
user: true
scope: user

+ 7
- 12
tasks/structure.yaml Dosyayı Görüntüle

@@ -1,22 +1,17 @@
---

- name: ~/bin directory
- name: bin directory
file:
path: ~/bin
state: directory

- name: binaries
copy:
src: bin/
dest: ~/bin
mode: 0755

- name: systemd user config directory
file:
path: ~/.config/systemd/user
state: directory

- name: eralitex directory
file:
path: "{{eralitex_directory}}"
state: directory

- name: profile directories
file:
path: "{{eralitex_directory}}/{{item}}"
state: directory
with_items: "{{ eralitex_profiles }}"

+ 6
- 0
tasks/vnc.yaml Dosyayı Görüntüle

@@ -24,3 +24,9 @@
src: ~/.vnc/passwd.{{item}}
dest: ~/.vnc/passwd.{{item}}
with_items: "{{ home_access_to_hosts }}"

- name: default vnc client options
template:
src: tigervnc.default.j2
dest: ~/.vnc/default.tigervnc
mode: 0755

+ 24
- 0
tasks/workspaces.yaml Dosyayı Görüntüle

@@ -0,0 +1,24 @@
---

- name: workspaces directory
file:
path: ~/.workspaces
state: directory

- name: workspace focus scripts
template:
src: workspace.focus.fish.j2
dest: ~/.workspaces/{{workspace}}.focus
mode: 0755
with_items: "{{workspaces|dict2items|json_query(\"[?value.type=='vdesk'].key\") }}"
loop_control:
loop_var: workspace

- name: workspace space shortcut scripts
template:
src: workspace.space.fish.j2
dest: ~/.workspaces/{{workspace}}.space
mode: 0755
with_items: "{{workspaces|dict2items|json_query(\"[?value.type=='vdesk'||value.type=='tmux'].key\") }}"
loop_control:
loop_var: workspace

+ 23
- 1
tasks/x11.yaml Dosyayı Görüntüle

@@ -1,6 +1,28 @@
---

- name: Xresources
template:
src: Xresources.j2
dest: ~/.Xresources

- name: Xmodmap
template:
src: Xmodmap.j2
dest: ~/.Xmodmap

- name: xsession script
template:
src: xsession.fish.j2
dest: ~/.xsession.fish
mode: 0755

- name: xsession reload script
template:
src: xsession.reload.fish.j2
dest: ~/.xsession.reload.fish
mode: 0755

- name: xsessionrc
copy:
content: exec fish {{eralitex_directory}}/active-profile/xsession
content: exec fish ~/.xsession.fish
dest: ~/.xsessionrc

+ 1
- 1
templates/Xmodmap.j2 Dosyayı Görüntüle

@@ -1,6 +1,6 @@
! {{ ansible_managed }}
!
! xmodmap {{eralitex_directory}}/Xmodmap
! xmodmap ~/.Xmodmap
!
! default modifier configuration
!


templates/urxvt.Xresources.j2 → templates/Xresources.j2 Dosyayı Görüntüle

@@ -1,6 +1,19 @@
! set font to Terminus
urxvt*font: xft:Terminus:pixelsize=14
urxvt*boldFont: xft:Terminus:pixelsize=14
! {{ansible_managed}}

! DPI
Xft.dpi: {{home_xft_dpi}}

! These might also be useful depending on your monitor and personal preference:
Xft.autohint: 0
Xft.lcdfilter: lcddefault
Xft.hintstyle: hintfull
Xft.hinting: 1
Xft.antialias: 1
Xft.rgba: rgb

! set fonts
URxvt.font:xft:Monospace:pixelsize=15
URxvt.boldfont:xft:Monospace-Bold:pixelsize=15

! set colors
URxvt*background: black

+ 52
- 41
templates/i3.config.j2 Dosyayı Görüntüle

@@ -5,11 +5,21 @@
# Please see http://i3wm.org/docs/userguide.html for a complete reference!

{% set workspace_switcher = "exec fish -c \"i3-msg workspace (i3-msg -t get_workspaces | jq --raw-output '.[]|select(.num == -1).name' | rofi -dmenu -p workspace )\"" %}
{% set on_focus_workspace = "exec --no-startup-id " + eralitex_directory + "/bin/on-focus-workspace" %}

{% set on_focus_workspace = "exec --no-startup-id ~/bin/on-focus-workspace" %}

### Font
font pango:Terminus 14px
#font pango:DejaVu Sans Mono 12
#font pango:DejaVu Sans Mono, Terminus Bold Semi-Condensed 11
#font pango:Droid Sans Mono Dotted 12
#font pango:DroidSansMono 13
#font pango:Sans 13
#font pango:hermit 12
#font pango:Inconsolata 14
font pango:monospace 10
#font pango:SourceCodePro-SemiBold 11
#font pango:Source Code Pro for Powerline, FontAwesome Regular, Icons 9
#font pango:Terminus 14px
#font pango:UbuntuMono-regular 12



@@ -31,10 +41,10 @@ set $right odiaeresis
### default/local mode

## special keys
bindsym XF86Sleep exec {{eralitex_lock_command}}
bindsym XF86Mail exec {{eralitex_mail_command}}
bindsym XF86HomePage exec {{eralitex_browser}}
bindsym XF86Calculator exec {{eralitex_calculator_command}}
bindsym XF86Sleep exec {{session_lock_command}}
bindsym XF86Mail exec {{mail_command}}
bindsym XF86HomePage exec {{default_browser}}
bindsym XF86Calculator exec {{calculator_command}}

## Special modes
bindsym $mod+t mode timer
@@ -44,17 +54,17 @@ bindcode $mod+49 mode "remote"


## Applications
bindsym $mod+Return exec "{{eralitex_terminal}}"
bindsym $mod+b exec "{{eralitex_browser}}"
bindsym $mod+Return exec "{{default_terminal}}"
bindsym $mod+b exec "{{default_browser}}"
bindsym $mod+d exec rofi -show drun -show-icons
bindsym $mod+e exec rofi -show run
bindsym $mod+a mode "apps"
bindsym $mod+space exec "{{eralitex_directory}}/bin/on-space-shortcut"
bindsym $mod+space exec "~/bin/on-space-shortcut"


## Workspaces
bindsym $mod+w {{workspace_switcher}}
{% for ws in eralitex_numbered_workspace_keymaps %}
{% for ws in i3_number_workspace_keymaps %}
bindsym $mod+{{ws.keysym}} workspace "{{ws.workspace}}"
{% endfor %}
# focus workspace
@@ -98,6 +108,8 @@ bindsym $mod+x exec xkill
# points
bindsym $mod+minus exec {{points_down_command}}
bindsym $mod+plus exec {{points_up_command}}
bindsym $mod+KP_Subtract exec {{points_down_command}}
bindsym $mod+KP_Add exec {{points_up_command}}

# unlearn
#exec {{points_down_command}}
@@ -106,15 +118,15 @@ bindsym $mod+plus exec {{points_up_command}}
## stuff that is available in default and remote mode
{% macro overall() %}

{% if item == "desktop" %}
bindsym $plexmod+space exec "{{eralitex_directory}}/bin/on-space-shortcut"
{% if home_profile == "desktop" %}
bindsym $plexmod+space exec ~/bin/on-space-shortcut
bindsym $plexmod+BackSpace kill
bindsym $plexmod+w {{workspace_switcher}}

{% for ws in eralitex_numbered_workspace_keymaps %}
{% for ws in i3_number_workspace_keymaps %}
bindsym $plexmod+{{ws.keysym}} workspace "{{ws.workspace}}"
{% endfor %}
{% for ws in eralitex_letter_workspace_keymaps %}
{% for ws in i3_letter_workspace_keymaps %}
bindsym $plexmod+{{ws.keysym}} workspace "{{ws.workspace}}"
{% endfor %}
# focus workspace
@@ -141,7 +153,7 @@ bindsym $mod+plus exec {{points_up_command}}
mode "remote" {

bindcode $mod+9 mode "default"
bindsym XF86Sleep exec {{eralitex_lock_command}}
bindsym XF86Sleep exec {{session_lock_command}}

# The middle button over a titlebar kills the window
bindsym --release button2 kill
@@ -154,7 +166,7 @@ mode "remote" {

### Applications mode
mode "apps" {
{% for a in eralitex_applications | dict2items %}
{% for a in application_shortcuts | dict2items %}
bindsym {{a.key}} exec {{a.value}}; mode "default"
{% endfor %}
bindsym Escape mode "default"
@@ -165,15 +177,15 @@ mode "apps" {
### Session
mode "session" {
bindsym q exit
bindsym r reload; exec --no-startup-id {{eralitex_directory}}/{{item}}/reload; mode "default"; {{on_focus_workspace}}
bindsym R reload; exec --no-startup-id {{eralitex_directory}}/{{item}}/reload; mode "default"; {{on_focus_workspace}}
bindsym s exec --no-startup-id {{eralitex_lock_command}}; exec --no-startup-{{eralitex_suspend_command}}; mode "default"; {{on_focus_workspace}}
bindsym x exec --no-startup-id {{eralitex_lock_command}}; mode "default"; {{on_focus_workspace}}
bindsym e exec --no-startup-id {{eralitex_enable_screensaver_command}}; mode "default"; {{on_focus_workspace}}
bindsym d exec --no-startup-id {{eralitex_disable_screensaver_command}}; mode "default"; {{on_focus_workspace}}
bindsym r reload; exec --no-startup-id ~/.xsession.reload.fish; mode "default"; {{on_focus_workspace}}
bindsym R reload; exec --no-startup-id ~/.xsession.reload.fish; mode "default"; {{on_focus_workspace}}
bindsym s exec --no-startup-id {{session_lock_command}}; exec --no-startup {{system_suspend_command}}; mode "default"; {{on_focus_workspace}}
bindsym x exec --no-startup-id {{session_lock_command}}; mode "default"; {{on_focus_workspace}}
bindsym e exec --no-startup-id {{session_enable_screensaver_command}}; mode "default"; {{on_focus_workspace}}
bindsym d exec --no-startup-id {{session_disable_screensaver_command}}; mode "default"; {{on_focus_workspace}}
bindsym b exec --no-startup-id xsetroot -solid black; mode "default"; {{on_focus_workspace}}
bindsym Shift+R exec --no-startup-id {{eralitex_reboot_command}}; mode "default"; {{on_focus_workspace}}
bindsym Shift+P exec --no-startup-id {{eralitex_poweroff_command}}; mode "default"; {{on_focus_workspace}}
bindsym Shift+R exec --no-startup-id {{system_reboot_command}}; mode "default"; {{on_focus_workspace}}
bindsym Shift+P exec --no-startup-id {{system_poweroff_command}}; mode "default"; {{on_focus_workspace}}

# back to normal: Escape
bindsym Escape mode "default"; {{on_focus_workspace}}
@@ -182,10 +194,10 @@ mode "session" {

### Timer
mode "timer" {
bindsym a exec "{{eralitex_directory}}/bin/timer activity"; mode "default"; {{on_focus_workspace}}
bindsym e exec "{{eralitex_directory}}/bin/timer end"; mode "default"; {{on_focus_workspace}}
bindsym r exec "{{eralitex_directory}}/bin/timer update"; mode "default"; {{on_focus_workspace}}
bindsym u exec "/opt/activity/activity 'Arbeit:Uniklinik Köln'"; mode "default"; {{on_focus_workspace}}
bindsym a exec "~/bin/timer activity"; mode "default"; {{on_focus_workspace}}
bindsym e exec "~/bin/timer end"; mode "default"; {{on_focus_workspace}}
bindsym r exec "~/bin/timer update"; mode "default"; {{on_focus_workspace}}
bindsym r exec "~/bin/timer uniklinik"; mode "default"; {{on_focus_workspace}}

# back to normal: Escape
bindsym Escape mode "default"; {{on_focus_workspace}}
@@ -237,7 +249,7 @@ mode "move" {
bindsym $right move right

# move window to workspace
{% for ws in eralitex_numbered_workspace_keymaps %}
{% for ws in i3_number_workspace_keymaps %}
bindsym {{ws.keysym}} move container to workspace "{{ws.workspace}}"; mode "default"
{% endfor %}
bindsym w exec fish -c "i3-msg move container to workspace (i3-msg -t get_workspaces | jq --raw-output '.[]|select(.num == -1).name' | rofi -dmenu -p 'move to workspace' )"; mode "default"
@@ -308,7 +320,7 @@ bar {

tray_output primary

status_command "i3blocks -c {{eralitex_directory}}/{{item}}/i3blocks.config"
status_command i3blocks

colors {
background #000000
@@ -316,15 +328,15 @@ bar {
separator #666666

# <colorclass> <border> <background> <text>
{% if item == "desktop" %}
{% if home_profile == "desktop" %}
# lila: Farbton 274
focused_workspace #774C99 #552877 #ffffff
{% endif %}
{% if item == "vdesk" %}
{% if home_profile == "vdesk" %}
# grün: Farbton 110
focused_workspace #4D994C #357728 #ffffff
{% endif %}
{% if item == "presentation" %}
{% if home_profile == "presentation" %}
# gelb: Farbton 60
focused_workspace #99994C #777728 #ffffff
{% endif %}
@@ -340,15 +352,15 @@ bar {
### Design

# class border backgr. text indicator child_border
{% if item == "desktop" %}
{% if home_profile == "desktop" %}
# lila: Farbton 274
client.focused #784C99 #552877 #ffffff #9E2EF4 #552877
{% endif %}
{% if item == "vdesk" %}
{% if home_profile == "vdesk" %}
# grün: Farbton 110
client.focused #59994C #357728 #ffffff #4FF42E #357728
{% endif %}
{% if item == "presentation" %}
{% if home_profile == "presentation" %}
# gelb: Farbton 60
client.focused #99994C #777728 #ffffff #F4F42E #777728
{% endif %}
@@ -373,6 +385,7 @@ focus_on_window_activation urgent
### Application specific rule

for_window [class="^Vncviewer$"] border none
for_window [class="^TigerVNC Viewer$"] border none
for_window [window_role="^About$"] floating enable
for_window [class="^Pavu"] floating enable
for_window [class="^Paman$"] floating enable
@@ -383,11 +396,9 @@ for_window [class="^URxvt$" title="^tmux-workspace$"] border none

### Autostart

exec "{{eralitex_terminal}}"
exec "{{default_terminal}}"

{% if item == "desktop" %}
exec --no-startup-id "{{eralitex_directory}}/bin/i3-watchers"
{% endif %}
exec --no-startup-id "~/bin/i3-watchers"

### free keys
# $mod+i


+ 1
- 1
templates/i3blocks.config.j2 Dosyayı Görüntüle

@@ -30,7 +30,7 @@ command=/usr/share/i3blocks/$BLOCK_NAME
separator_block_width=15
markup=none

{% if eralitex_with_activity %}
{% if with_activity %}
# activity
[activity]
command=/opt/activity/i3blocks-activity


+ 0
- 3
templates/other-workspace-focus.fish.j2 Dosyayı Görüntüle

@@ -1,3 +0,0 @@
#!/usr/bin/fish
{{ ansible_managed | comment }}
i3-msg mode default

+ 0
- 23
templates/reload.sh.j2 Dosyayı Görüntüle

@@ -1,23 +0,0 @@
#!/usr/bin/fish

# keymap
setxkbmap de
xmodmap {{eralitex_directory}}/Xmodmap
setxkbmap -option caps:hyper
xmodmap {{eralitex_directory}}/Xmodmap
xkbset nullify lock

# background
xsetroot -solid black
{% if eralitex_background_image is defined %}
{{eralitex_background_command}}
{% endif %}

# urxvt config
xrdb -merge {{eralitex_directory}}/urxvt.Xresources

# rofi config
rofi -theme {{eralitex_directory}}/{{item}}/rofi.theme -dump-xresources | xrdb -merge

# screensaver settings
/usr/local/bin/screensaver-settings

+ 4
- 4
templates/rofi.theme.j2 Dosyayı Görüntüle

@@ -24,22 +24,22 @@
active-background: #6A6A6A;

selected-urgent-background: #2f343a;
{% if item == "desktop" %}
{% if home_profile == "desktop" %}
selected-normal-background: #552877;
selected-active-background: #784C99;
{% endif %}
{% if item == "vdesk" %}
{% if home_profile == "vdesk" %}
selected-normal-background: #357728;
selected-active-background: #59994C;
{% endif %}
{% if item == "presentation" %}
{% if home_profile == "presentation" %}
selected-normal-background: #99994C;
selected-active-background: #777728;
{% endif %}

spacing: 2;

font: "Terminus 12";
font: "monospace 10";
}
#window {
background-color: @background;


+ 9
- 0
templates/tigervnc.default.j2 Dosyayı Görüntüle

@@ -0,0 +1,9 @@
TigerVNC Configuration file Version 1.0

MenuKey=Pause
#AutoSelect=0
#QualityLevel=0
#FullColor=0
#LowColorLevel=2
#PreferredEncoding=Tight
#CompressLevel=0

+ 4
- 4
templates/vdesk.service.j2 Dosyayı Görüntüle

@@ -11,17 +11,17 @@
# `loginctl enable-linger username`
#
# 3. The server can be enabled and started like this once configured:
# `systemctl --user start eralitex@:<display>.service`
# `systemctl --user enable eralitex@:<display>.service`
# `systemctl --user start vdesk@:<display>.service`
# `systemctl --user enable vdesk@:<display>.service`

[Unit]
Description=eralitex vdesk service - display %i
Description=vdesk service - display %i
After=syslog.target network.target

[Service]
Type=forking
ExecStartPre=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
ExecStart=/usr/bin/fish -c "/usr/bin/vncserver -xstartup {{eralitex_directory}}/vdesk/xsession %i"
ExecStart=/usr/bin/fish -c "/usr/bin/vncserver -xstartup ~/.xsession.fish %i"
ExecStop=/usr/bin/vncserver -kill %i

[Install]


+ 0
- 4
templates/vnc-options.fish.j2 Dosyayı Görüntüle

@@ -1,4 +0,0 @@
#!/usr/bin/fish
{{ ansible_managed | comment }}
#set -a vnc_options -MenuKey Pause
#set -a vnc_options -AutoSelect=0 -QualityLevel=0 -FullColor=0 -LowColorLevel=2 -PreferredEncoding=Tight -CompressLevel=0

templates/remote-workspace-focus.fish.j2 → templates/workspace.focus.fish.j2 Dosyayı Görüntüle


templates/remote-workspace-space.fish.j2 → templates/workspace.space.fish.j2 Dosyayı Görüntüle

@@ -1,8 +1,12 @@
#!/usr/bin/fish
{{ ansible_managed | comment }}

{% if workspaces[workspace].type == "vdesk" %}
source (dirname (status --current-filename))/vnc-options
xtigervncviewer localhost:{{workspaces[workspace].display|default(16)}} -via {{workspaces[workspace].host}} -PasswordFile ~/.vnc/passwd.{{workspaces[workspace].host}}

{% elif workspaces[workspace].type == "tmux" %}

urxvt -title tmux-workspace -e fish -c 'ssh -t {{workspaces[workspace].host}} tmux attach -d -t {{workspaces[workspace].session}}'

{% endif %}

templates/xsession.sh.j2 → templates/xsession.fish.j2 Dosyayı Görüntüle

@@ -2,29 +2,27 @@

{{ ansible_managed | comment }}



# set PATH so it includes users
# private bin directory if it exists
if test -d "$HOME/bin"
set -x PATH "$HOME/bin:$PATH"
end

# reload script
source {{eralitex_directory}}/{{item}}/reload
# xsession reload script
source ~/.xsession-reload.fish

{% if item != "vdesk" %}
{% if home_profile != "vdesk" %}
blueman-applet &
pasystray &
nm-applet &
{% endif %}

{% if item != "presentation" and item != "vdesk" %}
{% if home_profile != "presentation" and home_profile != "vdesk" %}
/usr/local/bin/screensaver-start &
{% endif %}

{% if item == "presentation" %}
{% if home_profile == "presentation" %}
unclutter &
{% endif %}

exec /usr/bin/i3 -c {{eralitex_directory}}/{{item}}/i3.config
exec /usr/bin/i3

+ 23
- 0
templates/xsession.reload.fish.j2 Dosyayı Görüntüle

@@ -0,0 +1,23 @@
#!/usr/bin/fish

# keymap
setxkbmap de
xmodmap ~/.Xmodmap
setxkbmap -option caps:hyper
xmodmap ~/.Xmodmap
xkbset nullify lock

# background
xsetroot -solid black
{% if background_image is defined %}
{{background_command}}
{% endif %}

# Xresources
xrdb -merge ~/.Xresources

# rofi
rofi -theme ~/.config/rofi/theme -dump-xresources > ~/.config/rofi/config

# screensaver settings
/usr/local/bin/screensaver-settings

+ 6
- 11
vars/main.yaml Dosyayı Görüntüle

@@ -1,9 +1,4 @@
eralitex_profiles:
- desktop
- vdesk
- presentation

eralitex_numbered_workspace_keymaps:
i3_number_workspace_keymaps:
- keysym: 1
workspace: 1
- keysym: 2
@@ -50,7 +45,7 @@ eralitex_numbered_workspace_keymaps:
workspace: 22


eralitex_letter_workspace_keymaps:
i3_letter_workspace_keymaps:
- keysym: a
workspace: 23:a
- keysym: b
@@ -112,8 +107,8 @@ eralitex_letter_workspace_keymaps:
- keysym: ssharp
workspace: 52:ß

points_up_command: fish -c "echo (expr (cat ~/.eralitex/points) + 1 > ~/.eralitex/points) (i3-nagbar -m (cat ~/.eralitex/points)\ Ω)"
points_down_command: fish -c "echo (expr (cat ~/.eralitex/points) - 1 > ~/.eralitex/points) (i3-nagbar -m (cat ~/.eralitex/points)\ Ω)"
points_up_command: fish -c "echo (expr (cat ~/.points) + 1 > ~/.points) (rofi -m (cat ~/.points)\ Ω)"
points_down_command: fish -c "echo (expr (cat ~/.points) - 1 > ~/.points) (rofi -m (cat ~/.points)\ Ω)"

eralitex_background_image_path: "{{eralitex_directory}}/backgrounds/{{eralitex_background_image|basename}}"
eralitex_background_command: feh --no-fehbg --bg-fill {{eralitex_background_image_path}}
background_image_path: ~/.backgrounds/{{background_image|basename}}
background_command: feh --no-fehbg --bg-fill {{background_image_path}}