diff --git a/.i3/config b/.i3/config index c638dd9..c96b81e 100755 --- a/.i3/config +++ b/.i3/config @@ -55,6 +55,8 @@ bindsym Control+space exec rofi -show combi -modi combi -lines 7 -eh 2 -width 10 # Pulse Audio controls ## requires alsa-utils pulseaudio +#bindsym XF86AudioRaiseVolume exec --no-startup-id pactl -- set-sink-volume 0 +5% pactl -- set-sink-volume 12 +5% #increase sound volume +## Get RUNNING sinks - pactl list sinks | grep RUNNING -B 1 -A 1 bindsym XF86AudioRaiseVolume exec --no-startup-id pactl -- set-sink-volume 0 +5% #increase sound volume bindsym XF86AudioLowerVolume exec --no-startup-id pactl -- set-sink-volume 0 -5% #decrease sound volume bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute 0 toggle # mute sound diff --git a/config/terminator/config b/config/terminator/config index 65b5757..fbc3a80 100755 --- a/config/terminator/config +++ b/config/terminator/config @@ -58,78 +58,10 @@ show_titlebar = False [profiles] [[default]] - background_color = "#1d1f21" + background_color = "#fcaf3e" cursor_color = "#c5c8c6" foreground_color = "#c5c8c6" - palette = "#282a2e:#a54242:#8c9440:#de935f:#5f819d:#85678f:#5e8d87:#707880:#373b41:#cc6666:#b5bd68:#f0c674:#81a2be:#b294bb:#8abeb7:#c5c8c6" - scrollback_infinite = True - scrollbar_position = hidden - show_titlebar = False - use_system_font = False - [[4bit-1461701505408]] - background_color = "#8d8dcf" - foreground_color = "#d9e6f2" - palette = "#000000:#b87a7a:#7ab87a:#b8b87a:#7a7ab8:#b87ab8:#7ab8b8:#d9d9d9:#262626:#dbbdbd:#bddbbd:#dbdbbd:#bdbddb:#dbbddb:#bddbdb:#ffffff" - [[AtelierSulphurpool]] - background_color = "#202746" - cursor_color = "#979db4" - foreground_color = "#979db4" - palette = "#202746:#c94922:#ac9739:#c08b30:#3d8fd1:#6679cc:#22a2c9:#979db4:#6b7394:#c76b29:#293256:#5e6687:#898ea4:#dfe2f1:#9c637a:#f5f7ff" - [[Bright Lights]] - background_color = "#191919" - cursor_color = "#f34b00" - foreground_color = "#b3c9d7" - palette = "#191919:#ff355b:#b7e876:#ffc251:#76d4ff:#ba76e7:#6cbfb5:#c2c8d7:#191919:#ff355b:#b7e876:#ffc251:#76d5ff:#ba76e7:#6cbfb5:#c2c8d7" - [[Broadcast]] - background_color = "#2b2b2b" - cursor_color = "#ffffff" - foreground_color = "#e6e1dc" - palette = "#000000:#da4939:#519f50:#ffd24a:#6d9cbe:#d0d0ff:#6e9cbe:#ffffff:#323232:#ff7b6b:#83d182:#ffff7c:#9fcef0:#ffffff:#a0cef0:#ffffff" - [[Brogrammer]] - background_color = "#131313" - cursor_color = "#b9b9b9" - foreground_color = "#d6dbe5" - palette = "#1f1f1f:#f81118:#2dc55e:#ecba0f:#2a84d2:#4e5ab7:#1081d6:#d6dbe5:#d6dbe5:#de352e:#1dd361:#f3bd09:#1081d6:#5350b9:#0f7ddb:#ffffff" - [[DotGov]] - background_color = "#262c35" - cursor_color = "#d9002f" - foreground_color = "#ebebeb" - palette = "#191919:#bf091d:#3d9751:#f6bb34:#17b2e0:#7830b0:#8bd2ed:#ffffff:#191919:#bf091d:#3d9751:#f6bb34:#17b2e0:#7830b0:#8bd2ed:#ffffff" - [[Dracula]] - background_color = "#1e1f29" - cursor_color = "#aaaaaa" - foreground_color = "#f8f8f2" - palette = "#44475a:#ff5555:#50fa7b:#f1fa8c:#8be9fd:#bd93f9:#ff79c6:#94a3a5:#000000:#ff5555:#50fa7b:#f1fa8c:#8be9fd:#bd93f9:#ff79c6:#ffffff" - [[Github]] - background_color = "#f4f4f4" - cursor_color = "#3f3f3f" - foreground_color = "#3e3e3e" - palette = "#3e3e3e:#970b16:#07962a:#f8eec7:#003e8a:#e94691:#89d1ec:#ffffff:#666666:#de0000:#87d5a2:#f1d007:#2e6cba:#ffa29f:#1cfafe:#ffffff" - [[Smyck]] - background_color = "#2d2d2d" - cursor_color = "#c75646" - foreground_color = "#f7f7f7" - palette = "#000000:#c75646:#8eb33b:#d0b03c:#72b3cc:#c8a0d1:#218693:#b0b0b0:#5d5d5d:#e09690:#cdee69:#ffe377:#9cd9f0:#fbb1f9:#77dfd8:#f7f7f7" - [[default_old]] - audible_bell = True - background_color = "#fdf6e3" - background_darkness = 0.87 - cursor_color = "#c75646" - font = Hack 10 - foreground_color = "#657b83" - palette = "#073642:#dc322f:#859900:#b58900:#268bd2:#d33682:#2aa198:#eee8d5:#002b36:#cb4b16:#586e75:#657b83:#839496:#6c71c4:#93a1a1:#fdf6e3" - scrollback_infinite = True - scrollbar_position = hidden - show_titlebar = False - use_system_font = False - [[old]] - audible_bell = True - background_color = "#002b36" - cursor_color = "#fc531d" - font = Monospace 8 - foreground_color = "#839496" - icon_bell = False - palette = "#073642:#dc322f:#859900:#b58900:#268bd2:#d33682:#2aa198:#eee8d5:#002b36:#cb4b16:#586e75:#657b83:#839496:#6c71c4:#93a1a1:#fdf6e3" + palette = "#f57900:#a54242:#8c9440:#de935f:#5f819d:#85678f:#5e8d87:#707880:#373b41:#cc6666:#b5bd68:#f0c674:#81a2be:#b294bb:#8abeb7:#c5c8c6" scrollback_infinite = True scrollbar_position = hidden show_titlebar = False diff --git a/config/terminator/plugins/terminator-themes.py b/config/terminator/plugins/terminator-themes.py new file mode 100644 index 0000000..ad6e4d3 --- /dev/null +++ b/config/terminator/plugins/terminator-themes.py @@ -0,0 +1,176 @@ +import requests +import terminatorlib.plugin as plugin +from gi.repository import Gtk +from terminatorlib.config import ConfigBase +from terminatorlib.translation import _ +from terminatorlib.util import get_config_dir, err, dbg, gerr + +AVAILABLE = ['TerminatorThemes'] + +class TerminatorThemes(plugin.Plugin): + + capabilities = ['terminal_menu'] + config_base = ConfigBase() + base_url = 'https://api.github.com/repos/EliverLara/terminator-themes/contents/schemes' + def callback(self, menuitems, menu, terminal): + """Add our item to the menu""" + self.terminal = terminal + item = Gtk.ImageMenuItem(Gtk.STOCK_FIND) + item.connect('activate',self.configure) + item.set_label("Themes") + item.set_sensitive(True) + menuitems.append(item) + + def configure(self, widget, data = None): + ui = {} + + dbox = Gtk.Dialog( + _("Terminator themes"), + None, + Gtk.DialogFlags.MODAL, + ( + + _("_Close"), Gtk.ResponseType.ACCEPT + ) + ) + + self.liststore = Gtk.ListStore(str, bool) + + profiles_from_repo = [] + response = requests.get(self.base_url) + + if response.status_code != 200: + gerr(_("Failed to get list of available themes")) + return + + for repo in response.json(): + profiles_from_repo.append(repo['name']) + + + profiles = self.terminal.config.list_profiles() + + # Set add/remove buttons availability + for profile in profiles_from_repo: + profile = profile.split(".") + if profile[0] in profiles: + self.liststore.append([profile[0], False]) + else: + self.liststore.append([profile[0], True]) + + + treeview = Gtk.TreeView(self.liststore) + + selection = treeview.get_selection() + + selection.set_mode(Gtk.SelectionMode.SINGLE) + selection.connect("changed", self.on_selection_changed, ui) + ui['treeview'] = treeview + + renderer_text = Gtk.CellRendererText() + column_text = Gtk.TreeViewColumn("Theme", renderer_text, text=0) + treeview.append_column(column_text) + + + scroll_window = Gtk.ScrolledWindow() + scroll_window.set_size_request(500, 250) + scroll_window.set_policy(Gtk.PolicyType.AUTOMATIC, Gtk.PolicyType.AUTOMATIC) + scroll_window.add_with_viewport(treeview) + + hbox = Gtk.HBox() + hbox.pack_start(scroll_window, True, True, 0) + dbox.vbox.pack_start(hbox, True, True, 0) + + button_box = Gtk.VBox() + + button = Gtk.Button(_("Install")) + button_box.pack_start(button, False, True, 0) + button.connect("clicked", self.on_install, ui) + button.set_sensitive(False) + ui['button_install'] = button + + button = Gtk.Button(_("Remove")) + button_box.pack_start(button, False, True, 0) + button.connect("clicked", self.on_uninstall, ui) + button.set_sensitive(False) + ui['button_uninstall'] = button + + hbox.pack_start(button_box, False, True, 0) + self.dbox = dbox + dbox.show_all() + res = dbox.run() + if res == Gtk.ResponseType.ACCEPT: + self.terminal.config.save() + del(self.dbox) + dbox.destroy() + return + + + def on_selection_changed(self, selection, data=None): + (model, iter) = selection.get_selected() + data['button_install'].set_sensitive(model[iter][1]) + data['button_uninstall'].set_sensitive(model[iter][1] is not True) + + def on_uninstall(self, button, data): + + treeview = data['treeview'] + selection = treeview.get_selection() + (store, iter) = selection.get_selected() + target = store[iter][0] + + # If selected theme is active, sets terminal profile to default before unistalling + if self.terminal.get_profile() == target: + widget = self.terminal.get_vte() + self.terminal.force_set_profile(widget, 'default') + + self.terminal.config.del_profile(target) + self.terminal.config.save() + + #'Add' button available again + self.liststore.set_value(iter, 1, True) + self.on_selection_changed(selection, data) + + def on_install(self, button, data): + treeview = data['treeview'] + selection = treeview.get_selection() + (store, iter) = selection.get_selected() + target = store[iter][0] + widget = self.terminal.get_vte() + treeview.set_enable_tree_lines(False) + + if not iter: + return + + + headers = { "Accept": "application/vnd.github.v3.raw" } + response = requests.get(self.base_url+ '/' + target + '.config', headers=headers) + + if response.status_code != 200: + gerr(_("Failed to download selected theme")) + return + + # Creates a new profile and overwrites the default colors for the new theme + self.terminal.config.add_profile(target) + target_data = self.make_dictionary(response.content) + for k, v in target_data.items(): + if k != 'background_image': + self.config_base.set_item(k, v[1:-1], target) + + self.terminal.force_set_profile(widget, target) + self.terminal.config.save() + + # "Remove" button available again + self.liststore.set_value(iter, 1, False) + self.on_selection_changed(selection, data) + treeview.set_enable_tree_lines(True) + + def make_dictionary(self, data): + arr = [] + out_dict = {} + for line in data.split("\n"): + arr.append(line.split("=")) + + for item in arr: + if len(item) > 1: + out_dict[item[0].strip()] = item[1].strip() + + return out_dict diff --git a/config/terminator/plugins/terminator-themes.pyc b/config/terminator/plugins/terminator-themes.pyc new file mode 100644 index 0000000..ef5fe73 Binary files /dev/null and b/config/terminator/plugins/terminator-themes.pyc differ diff --git a/git/.gitconfig b/git/.gitconfig index d8c4819..996fbfb 100755 --- a/git/.gitconfig +++ b/git/.gitconfig @@ -7,8 +7,3 @@ autostash = true [core] editor = vim -[filter "lfs"] - clean = git-lfs clean -- %f - smudge = git-lfs smudge -- %f - process = git-lfs filter-process - required = true diff --git a/run/.bashrc b/run/.bashrc index 56818b0..55d831b 100755 --- a/run/.bashrc +++ b/run/.bashrc @@ -176,7 +176,7 @@ run_on_prompt_command() log_bash_persistent_history } -PROMPT_COMMAND="run_on_prompt_command && _powerline_set_prompt" +#PROMPT_COMMAND="run_on_prompt_command && _powerline_set_prompt" ## Keyboard Mapping!!! setxkbmap dvorak @@ -190,4 +190,4 @@ export XDG_CURRENT_DESKTOP=GNOME alias nemo='nemo --no-desktop' eval `dircolors ~/.vimspectr-shell/dircolors` -[ -n "$PS1" ] && sh ~/.vimspectr-shell/vimspectr60flat-dark +[ -n "$PS1" ] && sh ~/.vimspectr-shell/vimspectr90wflat-dark diff --git a/run/.profile b/run/.profile index 8d8a806..ae52a30 100644 --- a/run/.profile +++ b/run/.profile @@ -33,4 +33,3 @@ export LESS_TERMCAP_us=$'\e'"[1;32m" ## Add Applications to Path export PATH="$HOME/bin:$HOME/.local/bin:/opt:$PATH" export XDG_CURRENT_DESKTOP=GNOME - diff --git a/system/.vimrc b/system/.vimrc index d764c3a..f38774f 100755 --- a/system/.vimrc +++ b/system/.vimrc @@ -17,8 +17,8 @@ Plugin 'nightsense/vimspectr' call vundle#end() " Themes from https://github.com/nightsense/vimspectr -colorscheme vimspectr60flat-dark -let g:vimspectr60flat_dark_StatusLine = 'orange' +colorscheme vimspectr90wflat-dark +"let g:vimspectr60flat_dark_StatusLine = 'orange' "execute pathogen#infect('bundle/{}') filetype plugin indent on " filetype detection[ON] plugin[ON] indent[ON] diff --git a/vim/bundle/Vundle.vim b/vim/bundle/Vundle.vim index 5d9b059..6437ad6 160000 --- a/vim/bundle/Vundle.vim +++ b/vim/bundle/Vundle.vim @@ -1 +1 @@ -Subproject commit 5d9b05970140aa975bfb7d4350abf349c1451802 +Subproject commit 6437ad6df4a3e6a87c5fb8bd2b8aadb277ec9c87 diff --git a/vim/bundle/ansible-vim b/vim/bundle/ansible-vim index 8540ad7..5f3eb14 160000 --- a/vim/bundle/ansible-vim +++ b/vim/bundle/ansible-vim @@ -1 +1 @@ -Subproject commit 8540ad7ff0f8da2b31b5c55e6ae52ad87221e918 +Subproject commit 5f3eb14ba74bb9bc7c1356b45ab2a981825ca3ca