Package: pycritty
PycrittyChange your alacritty config on the fly!Installation:pipinstallpycrittyBy default, only the program itself will be installed, but you can install
default themes fromconfig/themes:pipinstall--install-option="--themes=onedark,dracula,nord"pycrittyOr if you want them all:pipinstall--install-option="--themes=all"pycrittyMake sure to have~/.local/bindirectory in your$PATH, otherwise
your shell won't find thepycrittycommand. Add this line to your~/.xprofileif you haven't already:exportPATH=$HOME/.local/bin:$PATHAlso if you are an Arch user you can install from the AUR (only the program will be installed)gitclonehttps://aur.archlinux.org/pycritty.gitcdpycritty
makepkg-siOr with an AUR helper like yayyay-SpycrittyUsage:Change your current config:pycritty--fontUbuntuMono--font-size14--opacity0.95--padding33Save multiple configs and reuse them later:pycrittysaveThisConfig
pycrittyloadAnotherConfigInstall themes and configs from URLs:pycrittyinstall--themehttps://raw.githubusercontent.com/antoniosarosi/pycritty/master/config/themes/breeze.yaml
pycritty--themebreeze# Apply downloaded themepycrittyinstall--config--nameSomeCoolConfighttps://raw.githubusercontent.com/antoniosarosi/dotfiles/master/.config/alacritty/config.yaml
pycrittyloadSomeCoolConfig# Apply downloaded configCheck help for all available options:pycritty-h# pycritty subcomand -hpycrittysave-hFonts ConfigFonts are configured at~/.config/alacritty/fonts.yamlwith this format:fonts:Alias:Font NameWhen applied usingpycritty -f Alias, the previous format will be
converted into the alacritty equivalent:font:normal:family:Font Nameitalic:family:Font Namebold:family:Font NameYou can also specify a different font for each font type:fonts:Alias:normal:Normal Font Namebold:Bold Font Nameitalic:Italic Font NameNote that the fonts must be installed on your system.Theme ConfigYou can make your own custom themes by creating new theme files with the
correct format,~/.config/alacritty/themes/custom.yamlshould look like
this:colors:# Default colorsprimary:background:'0x292d3e'foreground:'0xbbc5ff'# Normal colorsnormal:black:'0x101010'red:'0xf07178'green:'0xc3e88d'yellow:'0xffcb6b'blue:'0x82aaff'magenta:'0xc792ea'cyan:'0x89ddff'white:'0xd0d0d0'# Bright colorsbright:black:'0x434758'red:'0xff8b92'green:'0xddffa7'yellow:'0xffe585'blue:'0x9cc4ff'magenta:'0xe1acff'cyan:'0xa3f7ff'white:'0xffffff'Then you can apply it using the name of the file:pycritty-tcustomCustom scriptsIf you want to apply different configs programmatically, you can either use
the CLI in a shell script or usepycrittyas a python module:#!/bin/python3# Dummy script that changes the theme every 5 minutesimporttimeimportpycrittydefmain():config=pycritty.Config()whileTrue:forthemeinpycritty.list_themes():config.change_theme(theme)# or config.set(theme=theme)config.apply()time.sleep(300)if__name__=='__main__':main()Shell equivalent:#!/bin/bashwhile:;do# Same as pycritty ls --themes --iterableforthemein$(pycrittyls-ti);dopycritty-t$themesleep300donedoneDevelopmentClone the repository and run it as a module.gitclonegit@github.com:antoniosarosi/pycrittycdpycritty
python-mpycritty.mainPublishingPyPi# First make sure you have these packages installedpipinstall--user--upgradesetuptoolswheeltwine# Generate distribution filespythonsetup.pysdistbdist_wheel# Test uploadpython-mtwineupload--repositorytestpypidist/*# Test downloadpipinstall-ihttps://test.pypi.org/simple/--no-depspycritty# Upload to PyPipython-mtwineupload--repositorypypidist/*