Skip to content

About

A place for me to store all my silly linix/unix configuration files.

Resources

Stars

2 stars

Watchers

1 watching

Forks

Repository files navigation

blakecode-linux-configs

A place for me to store all my silly linux/unix configuration files.

Installation

First Time Setup

  1. Clone this repository:

    git clone git@github.com:Djspaceg/blakecode-linux-configs.git
    cd blakecode-linux-configs
  2. Run the installation script:

    ./install.sh
  3. Follow the prompts to:

    • Set a hostname for this machine (e.g., "CandyKingdom", "JungleFort")
    • Backup and merge any existing config files
    • Create symlinks to your home directory
  4. Restart your shell or source the new config:

    source ~/.zshrc  # or ~/.bashrc

What the installer does

  • Prompts for a custom hostname (stored in ~/.bc-hostname)
  • Creates machine-configs/$HOSTNAME/ for machine-specific configs
  • Backs up existing config files to ~/.config-backup-TIMESTAMP/
  • Migrates existing configs to your machine-specific folder
  • Creates symlinks from ~/.profileconfig to your home directory

Machine-Specific Configuration

After installation, customize your machine by editing files in:

machine-configs/$HOSTNAME/

These files override the base configuration for this specific machine.

Structure

See STRUCTURE.md for detailed documentation on:

  • File execution order for bash and zsh
  • What belongs in each file (zshenv vs zshrc vs zprofile)
  • Machine-specific configuration
  • PATH construction
  • History file management

Legacy Setup

The old ./configure script is still available but doesn't handle hostname setup or config migration. Use ./install.sh instead.

Purging old Kiro session history

scripts/purge-kiro-sessions.mjs previews and (optionally) deletes OLD Kiro chat/session histories from this machine. It is dependency-free but requires Node.js 18+. The script has a Node shebang and is executable, so you can run it directly (./scripts/purge-kiro-sessions.mjs); node scripts/purge-kiro-sessions.mjs works too.

Preview is the default. Running it with no flags lists what it would remove and deletes nothing. You must pass --delete to actually remove anything.

# Preview everything older than 30 days (default):
./scripts/purge-kiro-sessions.mjs

# Preview a different retention window:
./scripts/purge-kiro-sessions.mjs --days 90

# Actually delete histories older than 30 days:
./scripts/purge-kiro-sessions.mjs --delete

Before you run --delete:

  • Quit Kiro first. --delete refuses to run while the Kiro IDE, Kiro Helper, or kiro-cli is running. (A dry-run still works while Kiro is open, and warns you that an apply would refuse.)
  • Export any chats you want to keep first. Deletion is permanent.
  • Review the dry-run output before scheduling this in cron or a launch agent, so you know exactly what the retention window will catch.

What it covers:

  • Current IDE chat histories (~/.kiro/sessions/<bucket>/<session>), including their bucket index, the append-only visibility indexes in ~/.kiro/session-index/, and spec-session links in ~/.kiro/spec-sessions/.
  • CLI histories (~/.kiro/sessions/cli/<uuid>.json and companions).
  • Recognized legacy IDE histories under the VS Code-style global storage (.../globalStorage/kiro.kiroagent/sessions and .../workspace-sessions/*). For a legacy session that is being deleted, its exact per-session migration marker companions (._migration-<sessionId>.json and .migrated-<sessionId>.json, if present) are removed alongside that session's own record — they are part of the record, not shared migration state.

What it deliberately leaves alone: settings, extensions, logs, code indexes, workspace caches, and any cloud-synced sessions. Standalone migration, diff, cache, and index directories are excluded — it never walks or removes them. The only migration-related files it touches are the exact per-session marker companions named above, and only for a session it is already deleting. It only removes recognized local session histories.

Safety notes:

  • It never follows symlinks, validates every name and schema, enforces containment, and re-checks each target's type and identity immediately before deleting.
  • Anything it does not positively recognize (an unknown or future storage schema, a malformed index, an active/locked session) is skipped with a warning rather than guessed at.

This tool reads Kiro's internal on-disk storage formats directly — there is no documented bulk-delete API — and was verified against Kiro 1.1.11-insider. If a future Kiro release changes its storage format, the script will skip the unrecognized data (staying safe) and may need updating to recognize the new layout. Run ./scripts/purge-kiro-sessions.mjs --help for the full option and safety reference.

About

A place for me to store all my silly linix/unix configuration files.

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages