Skip to content

Simple configuration manager for dotfiles and system configuration files

License

Notifications You must be signed in to change notification settings

rivnakm/spaceconf

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

spaceconf

Simple configuration manager for dotfiles and system configuration files

Rust Test Action GitHub release (latest SemVer)

Features

File-Based Configuration Fixtures

{
    "type": "files",
    "files": [
        {
            "src": ".zshrc",
            "dest": "~/.zshrc"
        }
    ]
}

Git-Based Configuration Fixtures

{
    "type": "repository",
    "repository": "https://github.com/mrivnak/neovim-config",
    "reference": {
        "type": "branch",
        "value": "main"
    },
    "path": "~/.config/nvim"
}

File Templating with Tera

{% if hostname == "gentoo-desktop" -%}
monitor=DP-1, 3440x1440@165.00, 2560x0, 1
monitor=DP-2, 2560x1440@239.96, 0x0, 1
{% elif hostname == "gentoo-laptop" -%}
monitor=eDP-1, 2560x1440@165.00, 0x0, 1
{%- endif %}

Secrets support

Secrets that may be stored in existing config files, like an API key for a weather toolbar, can be obfuscated from your dotfiles repo and added on apply

<fixture_dir>/secrets.json

{
    "API_KEY": "12345abcde"
}

file.conf

get-data --api-key {{ API_KEY }}

Getting started

Installing from source

Requires Rust >=1.67

git clone https://github.com/mrivnak/spaceconf
cd spaceconf
cargo install --path .

Usage

spaceconf clone https://github.com/<username>/<dotfiles-repo>

You can then create subfolders in ~/.config/spaceconf/ with fixture.json files and associated config files. Then run...

spaceconf apply

About

Simple configuration manager for dotfiles and system configuration files

Resources

License

Stars

Watchers

Forks

Packages

No packages published