diff --git a/configs/gnome/desktop-settings.sh b/configs/gnome/desktop-settings.sh new file mode 100644 index 0000000..7ee8fbf --- /dev/null +++ b/configs/gnome/desktop-settings.sh @@ -0,0 +1,46 @@ +#! /bin/sh +# This script configures GNOME to my liking +set -e + +# Require gsettings +if ! command -v gsettings >/dev/null 2>&1; then + echo "gsettings is not installed, skipping some GNOME configuration" + exit 0 +fi + +# Mouse settings +gsettings set org.gnome.desktop.interface gtk-enable-primary-paste true # Middle click paste +gsettings set org.gnome.desktop.peripherals.touchpad disable-while-typing false # Allow touchpad while typing +gsettings set org.gnome.desktop.peripherals.touchpad natural-scroll false # Disable natural scrolling on touchpad + +# Keyboard settings +gsettings set org.gnome.desktop.wm.keybindings close "['q']" # Close windows with Mod+Shift+q +gsettings set org.gnome.desktop.wm.keybindings move-to-workspace-1 "['exclam']" # Move a window to ws 1 +gsettings set org.gnome.desktop.wm.keybindings move-to-workspace-2 "['at']" # Move a window to ws 2 +gsettings set org.gnome.desktop.wm.keybindings move-to-workspace-3 "['numbersign']" # Move a window to ws 3 +gsettings set org.gnome.desktop.wm.keybindings move-to-workspace-4 "['dollar']" # Move a window to ws 4 +gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-1 "['1']" # Switch to ws 1 +gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-2 "['2']" # Switch to ws 2 +gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-3 "['3']" # Switch to ws 3 +gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-4 "['4']" # Switch to ws 4 + +# Allow Mod+Enter to open a terminal +gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/ name "Open Terminal" +gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/ command "gnome-terminal" +gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/ binding "Return" + +# Top Bar settings +gsettings set org.gnome.desktop.interface clock-format 24h # 24 hour clock +gsettings set org.gnome.desktop.interface clock-show-date true # Show date in top bar +gsettings set org.gnome.desktop.interface clock-show-weekday true # Show weekday in top bar + +# Window settings +gsettings set org.gnome.desktop.wm.preferences focus-mode 'sloppy' # Focus windows on mouse hover +gsettings set org.gnome.desktop.wm.preferences auto-raise false # Don't auto-raise windows + +# Desktop settings +gsettings set org.gnome.desktop.interface enable-hot-corners false # Disable hot corners +gsettings set org.gnome.mutter edge-tiling true # Enable edge tiling +gsettings set org.gnome.mutter dynamic-workspaces false # Use a fixed number of workspaces +gsettings set org.gnome.desktop.wm.preferences num-workspaces 4 # Use 4 workspaces +gsettings set org.gnome.mutter workspaces-only-on-primary true # Only use workspaces on primary monitor diff --git a/configs/gnome/terminal/terminal.dconf b/configs/gnome/terminal/terminal.dconf new file mode 100644 index 0000000..c563b92 --- /dev/null +++ b/configs/gnome/terminal/terminal.dconf @@ -0,0 +1,7 @@ +[legacy/profiles:/:b1dcc9dd-5262-4d8d-a863-c897e6d979b9] +custom-command='/usr/bin/zsh' +default-size-columns=100 +default-size-rows=40 +login-shell=true +use-custom-command=true +visible-name='Default' diff --git a/configs/nvim/init.vim b/configs/nvim/init.vim index 1eba75c..e5034f5 100644 --- a/configs/nvim/init.vim +++ b/configs/nvim/init.vim @@ -40,13 +40,13 @@ endif " This is where the plugins be call plug#begin() -Plug 'github/copilot.vim' +" Plug 'github/copilot.vim' Plug 'tpope/vim-fugitive' Plug 'tpope/vim-surround' Plug 'jiangmiao/auto-pairs' Plug 'airblade/vim-gitgutter' Plug 'nathanaelkane/vim-indent-guides' -Plug 'ggandor/leap.nvim' +" Plug 'ggandor/leap.nvim' " And this is where the plugins no longer be call plug#end() @@ -67,7 +67,7 @@ hi IndentGuidesOdd ctermbg=darkgrey hi IndentGuidesEven ctermbg=lightgrey " Enable leap for jumping -lua require('leap').add_default_mappings() +" lua require('leap').add_default_mappings() " Make the gitgutter look cleaner let g:gitgutter_override_sign_column_highlight = 0 diff --git a/helpers/configure-gnome.sh b/helpers/configure-gnome.sh new file mode 100644 index 0000000..0faa1ff --- /dev/null +++ b/helpers/configure-gnome.sh @@ -0,0 +1,16 @@ +#! /bin/sh +set -e + +# Check if dconf is available +if ! command -v dconf >/dev/null 2>&1; then + echo "dconf is not installed, skipping GNOME configuration" + exit 0 +fi + +# Configure gnome-terminal +echo "Writing gnome-terminal settings..." +dconf load "/org/gnome/terminal/" < configs/gnome/terminal/terminal.dconf + +# Configure GNOME itself +echo "Writing GNOME settings..." +sh ./configs/gnome/desktop-settings.sh \ No newline at end of file diff --git a/install.conf.yaml b/install.conf.yaml index a869c5f..1a66dc7 100644 --- a/install.conf.yaml +++ b/install.conf.yaml @@ -28,4 +28,5 @@ - shell: - [git submodule update --init --recursive, Installing submodules] - [chmod +x configs/scripts/catto, Making catto executable] - - [chmod +x configs/scripts/aspath, Making aspath executable] \ No newline at end of file + - [chmod +x configs/scripts/aspath, Making aspath executable] + - [sh ./helpers/configure-gnome.sh, Configuring GNOME] \ No newline at end of file