Skip to content

Commit

Permalink
Update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
antoniosarosi committed Jan 16, 2021
1 parent c7da341 commit ecf0cec
Showing 1 changed file with 34 additions and 10 deletions.
44 changes: 34 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,33 @@ pip install --install-option="--themes=all" pycritty

## Usage:

Change your current config:

```bash
pycritty set --font UbuntuMono --size 14 --opacity 0.95
```

Save multiple configs and reuse them later:

```bash
pycritty save MyConfig
# 3 bugs later ...
pycritty load MyConfig
```

Install themes and configs from URLs:
```bash
pycritty install -t https://raw.githubusercontent.com/antoniosarosi/pycritty/master/config/themes/breeze.yaml
pycritty set -t breeze
pycritty install -c -n SomeCoolConfig https://raw.githubusercontent.com/antoniosarosi/dotfiles/master/.config/alacritty/config.yaml
pycritty load SomeCoolConfig
```

Check help for all available options:
```bash
pycritty --font UbuntuMono --size 14 --opacity 0.95
# Check all available options
pycritty --help
pycritty -h
# pycritty subcomand -h
pycritty set -h
```

## Fonts Config
Expand All @@ -38,7 +61,7 @@ fonts:
Alias: Font Name
```

When applied using ```pycritty -f Alias```, the previous format will be
When applied using ```pycritty set -f Alias```, the previous format will be
converted into the alacritty equivalent:

```yaml
Expand Down Expand Up @@ -100,7 +123,7 @@ colors:
Then you can apply it using the name of the file:

```bash
pycritty -t custom
pycritty set -t custom
```

## Custom scripts
Expand All @@ -112,15 +135,16 @@ the cli in a shell script or use ```pycritty``` as a python module:
# Dummy script that changes the theme every 10 minutes

from time import sleep
from pycritty.alacritty import Alacritty
from pycritty.commands import ListResource, SetConfig


def main():
alacritty = Alacritty()
ls = ListResource()
conf = SetConfig()
while True:
for theme in alacritty.list('themes'):
alacritty.change_theme(theme) # or alacritty.apply(theme=theme)
alacritty.save()
for theme in ls.list_themes():
conf.change_theme(theme) # or conf.set(theme=theme)
conf.apply()
sleep(600)


Expand Down

0 comments on commit ecf0cec

Please sign in to comment.