diff --git a/home/config/tmux/plugins/catppuccin/tmux/.editorconfig b/home/config/tmux/plugins/catppuccin/tmux/.editorconfig new file mode 100644 index 0000000..d86ac02 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.editorconfig @@ -0,0 +1,34 @@ +# EditorConfig helps developers define and maintain consistent +# coding styles between different editors and IDEs +# EditorConfig is awesome: https://EditorConfig.org + +root = true + +[*] +charset = utf-8 +indent_size = 2 +indent_style = space +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true + +# go +[*.go] +indent_style = tab +indent_size = 4 + +# python +[*.{ini,py,py.tpl,rst}] +indent_size = 4 + +# rust +[*.rs] +indent_size = 4 + +# documentation, utils +[*.{md,mdx,diff}] +trim_trailing_whitespace = false + +# windows shell scripts +[*.{cmd,bat,ps1}] +end_of_line = crlf diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/bug.yml b/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/bug.yml new file mode 100644 index 0000000..75d80a8 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/bug.yml @@ -0,0 +1,53 @@ +name: Bug Report +description: Report your bugs with the theme here! +labels: [bug] +body: + - type: checkboxes + attributes: + label: I am not requesting help with my configuration and believe something is genuinely broken. + description: Please open a [discussion](https://github.com/catppuccin/tmux/discussions/new?category=help) if you need support. + options: + - label: Something is really actually broken. + required: true + - type: checkboxes + attributes: + label: Is there an existing issue outlining your problem? + description: Please search to see if an issue already exists for your problem. + options: + - label: I have searched the existing issues and [troubleshooting guide](https://github.com/catppuccin/tmux/blob/main/docs/guides/troubleshooting.md), and they do not solve my problem. + required: true + - type: textarea + attributes: + label: Describe your problem. + description: Also tell us, what do you expect to see? + placeholder: The status bar is bright green, I expect it to be mantle. + validations: + required: true + - type: textarea + attributes: + label: Paste your configuration. + description: Provide us with the contents of your `~/.tmux.conf` file. + validations: + required: true + - type: textarea + attributes: + label: Attach screenshots. + description: If applicable, attach screenshots which clearly highlight the issue. + - type: input + attributes: + label: What tmux version are you seeing the issue on? + description: "You can find your version by running `tmux -V`" + placeholder: tmux 3.5a + validations: + required: true + - type: input + attributes: + label: What shell are you using? + description: "You can find your shell by running `echo $SHELL`" + placeholder: bash + validations: + required: true + - type: textarea + attributes: + label: Any additional comments? + description: Add any information that hasn't been covered in the previous sections! diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/config.yml b/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..8da1a2e --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,11 @@ +blank_issues_enabled: false +contact_links: + - name: Get Support + url: https://github.com/catppuccin/tmux/discussions/new?category=help + about: Need help tweaking your Catppuccin tmux configuration? Ask questions in GitHub Discussions! + - name: Show & Tell + url: https://github.com/catppuccin/tmux/discussions/new?category=show-tell + about: Want to showcase your customised Catppuccin tmux configuration? Show it off in GitHub Discussions! + - name: Community Discord + url: https://discord.com/servers/catppuccin-907385605422448742 + about: Chat to other community members! diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/enhancement.yml b/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/enhancement.yml new file mode 100644 index 0000000..1e2b053 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/enhancement.yml @@ -0,0 +1,18 @@ +name: Enhancement Issue +description: Request improvements to the theme here! +labels: [enhancement] +body: + - type: checkboxes + attributes: + label: Is there an existing issue outlining your improvement? + description: Please search to see if your improvement has already been raised as an issue. + options: + - label: I have searched the existing issues and my improvement has not been raised yet. + required: true + - type: textarea + attributes: + label: What would you like to see added and/or changed? + description: Make sure to mention why you think this is an improvement! + placeholder: I'd like to have an extra configuration option for... + validations: + required: true diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/meta.yml b/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/meta.yml new file mode 100644 index 0000000..f471d4a --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/ISSUE_TEMPLATE/meta.yml @@ -0,0 +1,18 @@ +name: Meta Issue +description: Raise any issue regarding the repository here! +labels: [meta] +body: + - type: checkboxes + attributes: + label: Is there an existing issue outlining your problem? + description: Please search to see if an issue already exists for your problem. + options: + - label: I have searched the existing issues and they do not solve my problem. + required: true + - type: textarea + attributes: + label: Describe your issue. + description: Bugs should be raised under a [Bug Report](https://github.com/catppuccin/tmux/issues/new?assignees=&labels=bug&template=bug.yml). + placeholder: The README is missing crucial information such as... + validations: + required: true diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/release-please-config.json b/home/config/tmux/plugins/catppuccin/tmux/.github/release-please-config.json new file mode 100644 index 0000000..0a2c059 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/release-please-config.json @@ -0,0 +1,27 @@ +{ + "last-release-sha": "408c02ccf44d0a59a7a63ce2b65c5c29982c5c0e", + "packages": { + ".": { + "release-type": "simple", + "changelog-path": "CHANGELOG.md", + "bump-minor-pre-major": true, + "bump-patch-for-minor-pre-major": false, + "draft": false, + "extra-files": [ + "README.md", + "docs/tutorials/01-getting-started.md" + ] + } + }, + "changelog-sections": [ + { "type": "feat", "section": "Added" }, + { "type": "change", "section": "Changed" }, + { "type": "fix", "section": "Fixed" }, + { "type": "deprecate", "section": "Deprecated" }, + { "type": "remove", "section": "Removed" }, + { "type": "perf", "section": "Performance Improvements" }, + { "type": "revert", "section": "Reverts" }, + { "type": "docs", "section": "Documentation" } + ], + "$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json" +} diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/release-please-manifest.json b/home/config/tmux/plugins/catppuccin/tmux/.github/release-please-manifest.json new file mode 100644 index 0000000..9965a34 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/release-please-manifest.json @@ -0,0 +1,3 @@ +{ + ".": "2.3.0" +} diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/release.yml b/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/release.yml new file mode 100644 index 0000000..911cf48 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/release.yml @@ -0,0 +1,45 @@ +on: + push: + branches: + - main + +permissions: + contents: write + pull-requests: write + +name: release-please + +jobs: + release-please: + runs-on: ubuntu-latest + steps: + - uses: googleapis/release-please-action@v4 + id: release + with: + token: ${{ secrets.GITHUB_TOKEN }} + config-file: .github/release-please-config.json + manifest-file: .github/release-please-manifest.json + - uses: actions/checkout@v6 + - name: tag major and minor versions + if: ${{ steps.release.outputs.release_created }} + run: | + git config user.name github-actions[bot] + git config user.email 41898282+github-actions[bot]@users.noreply.github.com + + git remote add gh-token "https://${{ secrets.GITHUB_TOKEN }}@github.com/googleapis/release-please-action.git" + + git tag -d latest || true + git tag -d v${{ steps.release.outputs.major }} || true + git tag -d v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} || true + + git push origin :latest || true + git push origin :v${{ steps.release.outputs.major }} || true + git push origin :v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} || true + + git tag -a latest -m "Release v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}" + git tag -a v${{ steps.release.outputs.major }} -m "Release v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}" + git tag -a v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} -m "Release v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}" + + git push origin latest + git push origin v${{ steps.release.outputs.major }} + git push origin v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/shellcheck.yml b/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/shellcheck.yml new file mode 100644 index 0000000..9d7289d --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/shellcheck.yml @@ -0,0 +1,32 @@ +--- +name: Shellcheck +permissions: + contents: read +on: + pull_request: + paths-ignore: + - "*.md" + - "assets/**" + push: + paths-ignore: + - "*.md" + - "assets/**" + branches: + - main + workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + +jobs: + shellcheck: + name: Shellcheck + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Run ShellCheck + uses: ludeeus/action-shellcheck@master + with: + additional_files: "catppuccin.tmux" + env: + SHELLCHECK_OPTS: "-a" diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/test.yml b/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/test.yml new file mode 100644 index 0000000..b4c8e51 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/test.yml @@ -0,0 +1,35 @@ +--- +name: Tests +permissions: + contents: read +on: + pull_request: + paths-ignore: + - "*.md" + - "assets/**" + push: + paths-ignore: + - "*.md" + - "assets/**" + branches: + - main + workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + +jobs: + ubuntu: + name: Test + runs-on: ubuntu-24.04 + + steps: + - name: Install tmux + run: sudo apt update && sudo apt install -y --allow-downgrades tmux=3.4-1build1 + - uses: actions/checkout@v6 + - name: Run Tests + shell: bash + run: | + bash --version + tmux -V + ./run_tests.sh diff --git a/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/whiskers-check.yml b/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/whiskers-check.yml new file mode 100644 index 0000000..1fc7be9 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.github/workflows/whiskers-check.yml @@ -0,0 +1,15 @@ +name: whiskers + +on: + workflow_dispatch: + push: + branches: [main] + pull_request: + branches: [main] + +jobs: + run: + uses: catppuccin/actions/.github/workflows/whiskers-check.yml@v1 + with: + args: tmux.tera + secrets: inherit diff --git a/home/config/tmux/plugins/catppuccin/tmux/.gitignore b/home/config/tmux/plugins/catppuccin/tmux/.gitignore new file mode 100644 index 0000000..beab4f1 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.gitignore @@ -0,0 +1,3 @@ +custom +!custom/README.md +!custom/example.sh diff --git a/home/config/tmux/plugins/catppuccin/tmux/.markdownlint.jsonc b/home/config/tmux/plugins/catppuccin/tmux/.markdownlint.jsonc new file mode 100644 index 0000000..6fb7438 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.markdownlint.jsonc @@ -0,0 +1,15 @@ +{ + "$schema": "https://raw.githubusercontent.com/DavidAnson/markdownlint/v0.35.0/schema/markdownlint-config-schema.json", + "line-length": { + "code_block_line_length": 120, + "tables": false + }, + "no-inline-html": { + "allowed_elements": ["details", "summary", "img", "p", "a", "h3"] + }, + "first-line-heading": false, + "no-alt-text": false, + "code-block-style": { + "style": "consistent" + } +} \ No newline at end of file diff --git a/home/config/tmux/plugins/catppuccin/tmux/.shellcheckrc b/home/config/tmux/plugins/catppuccin/tmux/.shellcheckrc new file mode 100644 index 0000000..3f7e5f5 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/.shellcheckrc @@ -0,0 +1,6 @@ +shell=bash + +# TODO: Find a way to declare color variables +disable=SC2154 + +external-sources=true diff --git a/home/config/tmux/plugins/catppuccin/tmux/CHANGELOG.md b/home/config/tmux/plugins/catppuccin/tmux/CHANGELOG.md new file mode 100644 index 0000000..766f0b6 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/CHANGELOG.md @@ -0,0 +1,222 @@ +# Changelog + +## [2.3.0](https://github.com/catppuccin/tmux/compare/v2.2.2...v2.3.0) (2026-04-08) + + +### Added + +* add RAM status module ([#570](https://github.com/catppuccin/tmux/issues/570)) ([4a9165b](https://github.com/catppuccin/tmux/commit/4a9165b2b029b57bbccc3bab488c3c8474a3056e)) + +## [2.2.2](https://github.com/catppuccin/tmux/compare/v2.2.1...v2.2.2) (2026-04-08) + + +### Fixed + +* Update status-line.md ([#528](https://github.com/catppuccin/tmux/issues/528)) ([4fb9e8d](https://github.com/catppuccin/tmux/commit/4fb9e8d10ed381981920054df8a449165efd23a6)) + +## [2.2.1](https://github.com/catppuccin/tmux/compare/v2.2.0...v2.2.1) (2026-04-07) + + +### Documentation + +* **03-resetting-theme:** remove tip ([#584](https://github.com/catppuccin/tmux/issues/584)) ([f451db9](https://github.com/catppuccin/tmux/commit/f451db96c8e4e7d9cdea7bbb0b57c149bfb40e28)) + +## [2.2.0](https://github.com/catppuccin/tmux/compare/v2.1.3...v2.2.0) (2026-04-07) + + +### Added + +* add a "reset" option to clear options on plugin load ([#500](https://github.com/catppuccin/tmux/issues/500)) ([556fea5](https://github.com/catppuccin/tmux/commit/556fea52bb5d827a42740bc605de4f1d8a0440de)) + + +### Fixed + +* change tmux plugin kube module uses ([#531](https://github.com/catppuccin/tmux/issues/531)) ([ef94979](https://github.com/catppuccin/tmux/commit/ef9497982032a9494f4bf3ad276fba58b61bd7e6)) +* **theme:** Cleanup duplicate palette theme color ([#562](https://github.com/catppuccin/tmux/issues/562)) ([efeb958](https://github.com/catppuccin/tmux/commit/efeb9583cec0bc7486caedbc309df0ea9505d332)) + + +### Documentation + +* clarify custom-status should be added before plugin is loaded ([#551](https://github.com/catppuccin/tmux/issues/551)) ([8b0b915](https://github.com/catppuccin/tmux/commit/8b0b9150f9d7dee2a4b70cdb50876ba7fd6d674a)) +* status-line left/right mixup ([#542](https://github.com/catppuccin/tmux/issues/542)) ([9d21d7c](https://github.com/catppuccin/tmux/commit/9d21d7ccd50df82bd732be2850ce2798e78b6391)) +* stop recommending `-o` ([#524](https://github.com/catppuccin/tmux/issues/524)) ([14a546f](https://github.com/catppuccin/tmux/commit/14a546fb64dc1141e5d02bac2185d8c1fd530d6a)) + +## [2.1.3](https://github.com/catppuccin/tmux/compare/v2.1.2...v2.1.3) (2025-03-23) + + +### Fixed + +* make the space in [@catppuccin](https://github.com/catppuccin)_window_flags_icon_format user-configurable ([#465](https://github.com/catppuccin/tmux/issues/465)) ([320e184](https://github.com/catppuccin/tmux/commit/320e184a31d0825cb4f4af550492cbdff2fc3ffc)) +* pomodoro plugin icon color - use a defined color (peach) rather than orange ([#466](https://github.com/catppuccin/tmux/issues/466)) ([da2143d](https://github.com/catppuccin/tmux/commit/da2143d2a6baf7951eda302678a57a171a78d78a)) +* use plain awk for the load status line module, removing a dep ([#508](https://github.com/catppuccin/tmux/issues/508)) ([c21246e](https://github.com/catppuccin/tmux/commit/c21246ed58e867c9594dc687c5e92b229bc1760d)) +* use the correct option for the left separator for the current window ([#450](https://github.com/catppuccin/tmux/issues/450)) ([ba9bd88](https://github.com/catppuccin/tmux/commit/ba9bd88c98c81f25060f051ed983e40f82fdd3ba)) + + +### Documentation + +* add a troubleshooting guide ([#473](https://github.com/catppuccin/tmux/issues/473)) ([ab647cf](https://github.com/catppuccin/tmux/commit/ab647cf91501cebbd3f967da2b488a5f87614e6b)) +* Correct the plugin path for TPM in the readme ([#492](https://github.com/catppuccin/tmux/issues/492)) ([ee8970d](https://github.com/catppuccin/tmux/commit/ee8970ddb5dd60fd93e254de9a30ed8277c7ccc7)) +* **README:** fix codeblock indentation ([#489](https://github.com/catppuccin/tmux/issues/489)) ([cce60ab](https://github.com/catppuccin/tmux/commit/cce60abc8efd7a641a5fcc8001e6b3ae61e8d5fe)) +* **README:** update migration guide issue link ([#493](https://github.com/catppuccin/tmux/issues/493)) ([073ee54](https://github.com/catppuccin/tmux/commit/073ee54992c59fedcc29c1525a26f95691f0ae1f)) + +## [2.1.2](https://github.com/catppuccin/tmux/compare/v2.1.1...v2.1.2) (2024-12-08) + + +### Fixed + +* improve uptime status sed script to report correct units for few uptime scenarios ([#437](https://github.com/catppuccin/tmux/issues/437)) ([31fc2bf](https://github.com/catppuccin/tmux/commit/31fc2bfb1123681dc06da613b944b85f81e4babd)) +* use current window separators for the current window format ([#443](https://github.com/catppuccin/tmux/issues/443)) ([2a6c45b](https://github.com/catppuccin/tmux/commit/2a6c45b7c0da1594de1105d6cef15e3e68981113)) + +## [2.1.1](https://github.com/catppuccin/tmux/compare/v2.1.0...v2.1.1) (2024-11-17) + + +### Fixed + +* escape the TPM environment variable in the kube status line module ([#434](https://github.com/catppuccin/tmux/issues/434)) ([eb78ade](https://github.com/catppuccin/tmux/commit/eb78ade9dc1f6cd8ba654572f51ddcae3c6e7fd7)) +* specify the color for right separator of the status modules to be the same as text bg color ([#429](https://github.com/catppuccin/tmux/issues/429)) ([0e66dee](https://github.com/catppuccin/tmux/commit/0e66dee11ee396824668d4db863f1873e9e9243f)) + + +### Documentation + +* add possible values for window_flags ([#417](https://github.com/catppuccin/tmux/issues/417)) ([c8a2d1a](https://github.com/catppuccin/tmux/commit/c8a2d1ae9649aa904960bef1516ea2ff9a3e6ad0)) +* **custom-status:** fix typo `catpuccin` -> `catppuccin` ([#424](https://github.com/catppuccin/tmux/issues/424)) ([aaf9120](https://github.com/catppuccin/tmux/commit/aaf9120f769a34e5491b3ee7f885c8c347f2f663)) + +## [2.1.0](https://github.com/catppuccin/tmux/compare/v2.0.0...v2.1.0) (2024-10-25) + + +### Added + +* add an option to format the window number with `[@catppuccin](https://github.com/catppuccin)_window_number` and `[@catppuccin](https://github.com/catppuccin)_window_current_number` ([c749885](https://github.com/catppuccin/tmux/commit/c74988511a462bdf07c5fc9ce88157b93a4ed185)) + + +### Fixed + +* allow for dynamic colors in status modules ([#411](https://github.com/catppuccin/tmux/issues/411)), fixes issue [#407](https://github.com/catppuccin/tmux/issues/407) ([5e273e4](https://github.com/catppuccin/tmux/commit/5e273e41dd3188a1a0e795b120623c95de491445)) +* session status icon bg color change by client_prefix ([#394](https://github.com/catppuccin/tmux/issues/394)) ([8855667](https://github.com/catppuccin/tmux/commit/885566714315915547516de5c2f1b660f8e524c2)) + + +### Documentation + +* **README:** add [@kjnsn](https://github.com/kjnsn) to "Thanks to" section ([#398](https://github.com/catppuccin/tmux/issues/398)) ([c3fab98](https://github.com/catppuccin/tmux/commit/c3fab98ab4248a2a78c8193ad48f0991b7bfa1e3)) + +## [2.0.0](https://github.com/catppuccin/tmux/compare/v1.0.3...v2.0.0) (2024-10-21) + + +### โš  BREAKING CHANGES + +* rebalance the colors used, and follow the styleguide +* change how windows are styled +* change how status modules are styled +* rebalance colors, adhere to style guide & overhaul docs ([#372](https://github.com/catppuccin/tmux/issues/372)) + +### Features + +* change how status modules are styled ([79284da](https://github.com/catppuccin/tmux/commit/79284da665bf5d39d304e23df4165c8ac37f9b7a)) +* rebalance colors, adhere to style guide & overhaul docs ([#372](https://github.com/catppuccin/tmux/issues/372)) ([79284da](https://github.com/catppuccin/tmux/commit/79284da665bf5d39d304e23df4165c8ac37f9b7a)) +* rebalance the colors used, and follow the styleguide ([79284da](https://github.com/catppuccin/tmux/commit/79284da665bf5d39d304e23df4165c8ac37f9b7a)) +* rebalance the status module colors for cpu and battery ([79284da](https://github.com/catppuccin/tmux/commit/79284da665bf5d39d304e23df4165c8ac37f9b7a)) +* replace `_ctp_status_bg` with unified `_ctp_module_bg_color` in module configuration ([a4d4ad0](https://github.com/catppuccin/tmux/commit/a4d4ad09cc8b5c9338cbd4510450d0ae997a7710)) + + +### Bug Fixes + +* **tests:** add tests for window styling ([79284da](https://github.com/catppuccin/tmux/commit/79284da665bf5d39d304e23df4165c8ac37f9b7a)) +* use ubuntu-24.04 in ci ([#388](https://github.com/catppuccin/tmux/issues/388)) ([3b0e0a6](https://github.com/catppuccin/tmux/commit/3b0e0a6f0741bf09149f23620516decd7b5f5ba5)) + + +### Code Refactoring + +* change how windows are styled ([79284da](https://github.com/catppuccin/tmux/commit/79284da665bf5d39d304e23df4165c8ac37f9b7a)) + +## [1.0.3](https://github.com/catppuccin/tmux/compare/v1.0.2...v1.0.3) (2024-10-16) + + +### Bug Fixes + +* change the default status line background to mantle ([#377](https://github.com/catppuccin/tmux/issues/377)) ([47dbe81](https://github.com/catppuccin/tmux/commit/47dbe818e3ad7a008ccbd3e5d69a29a4509f7d07)) + +## [1.0.2](https://github.com/catppuccin/tmux/compare/v1.0.1...v1.0.2) (2024-10-12) + + +### Bug Fixes + +* **ci:** update tmux in test workflow ([#370](https://github.com/catppuccin/tmux/issues/370)) ([02debd3](https://github.com/catppuccin/tmux/commit/02debd396802af9fe4b41601739e48ef38217533)) +* **status:** use a literal string for battery_icon so it can be replaced by the battery plugin ([#365](https://github.com/catppuccin/tmux/issues/365)) ([06fff2f](https://github.com/catppuccin/tmux/commit/06fff2f40ec4a5cd2c9e064bc7fde22130ecd4bb)), closes [#342](https://github.com/catppuccin/tmux/issues/342) +* typo in readme config example ([#362](https://github.com/catppuccin/tmux/issues/362)) ([41ee0b8](https://github.com/catppuccin/tmux/commit/41ee0b89acb3f4afe531209558d6b8e4d7d4ae1a)) +* **window:** middle separator colors ([#369](https://github.com/catppuccin/tmux/issues/369)) ([c59df83](https://github.com/catppuccin/tmux/commit/c59df83d68e64feb8d015c2eb3f8b90febc95a53)) + +## [1.0.1](https://github.com/catppuccin/tmux/compare/v1.0.0...v1.0.1) (2024-10-05) + + +### Bug Fixes + +* **readme:** fix the example configurations ([#343](https://github.com/catppuccin/tmux/issues/343)) ([06183b3](https://github.com/catppuccin/tmux/commit/06183b31216b4ed917760b3d59565e242eee6a64)) +* **readme:** fix the version number, and fix escaping in the custom status line module docs ([#357](https://github.com/catppuccin/tmux/issues/357)) ([db466f8](https://github.com/catppuccin/tmux/commit/db466f8c2dbcfdd84e501ee8274bdfdcf049d65d)) + +## [1.0.0](https://github.com/catppuccin/tmux/compare/v0.4.0...v1.0.0) (2024-10-02) + + +### Bug Fixes + +* **readme:** remove -F when setting the status line ([#333](https://github.com/catppuccin/tmux/issues/333)) ([b38421f](https://github.com/catppuccin/tmux/commit/b38421fa15d8dfafecaf6f438115cfe3c1259bf0)) + +## [0.4.0](https://github.com/catppuccin/tmux/compare/v0.3.0...v0.4.0) (2024-10-01) + + +### โš  BREAKING CHANGES + +* rewrite to use tmux native rather than bash ([#328](https://github.com/catppuccin/tmux/issues/328)) + +### Bug Fixes + +* **readme:** update the readme to include upgrade instructions ([1bcad05](https://github.com/catppuccin/tmux/commit/1bcad05f206fb4bb9706403da24b97d2cdb64bad)) +* **window:** ensure the window formats are set correctly ([#331](https://github.com/catppuccin/tmux/issues/331)) ([1bcad05](https://github.com/catppuccin/tmux/commit/1bcad05f206fb4bb9706403da24b97d2cdb64bad)) + + +### Code Refactoring + +* rewrite to use tmux native rather than bash ([#328](https://github.com/catppuccin/tmux/issues/328)) ([87fa4a0](https://github.com/catppuccin/tmux/commit/87fa4a08c5a7fdbef3130f05a8b12f0ca26d4a46)) + +## [0.3.0](https://github.com/catppuccin/tmux/compare/v0.2.0...v0.3.0) (2024-09-17) + + +### Features + +* **status:** Add support for status module middle separators ([#310](https://github.com/catppuccin/tmux/issues/310)) ([1612a23](https://github.com/catppuccin/tmux/commit/1612a23174a6771ac466312eb156f83b8b89d907)) +* **status:** window specific separator config ([#198](https://github.com/catppuccin/tmux/issues/198)) ([8276c5a](https://github.com/catppuccin/tmux/commit/8276c5a5e33dbbbae3d370db2f6129e20b402f8a)) + + +### Bug Fixes + +* **kube:** escape env var ([c31b9b2](https://github.com/catppuccin/tmux/commit/c31b9b2c6c7c50abbebd02b80c4fd32b2782a011)) + +## [0.2.0](https://github.com/catppuccin/tmux/compare/v0.1.0...v0.2.0) (2024-08-23) + + +### Features + +* error/warning messages on first load ([#278](https://github.com/catppuccin/tmux/issues/278)) ([a2dda02](https://github.com/catppuccin/tmux/commit/a2dda02b43194aec5deddf2890c28c76b4c11ed4)) +* warn users of whitespace in module lists ([#266](https://github.com/catppuccin/tmux/issues/266)) ([362a306](https://github.com/catppuccin/tmux/commit/362a306db71794f04d0995fc058bcaa094d1af70)) + + +### Bug Fixes + +* add missing batch options `catppuccin_pane{,_active}_border_style` ([3ffbc37](https://github.com/catppuccin/tmux/commit/3ffbc3700b4c1c3e2c4d015c5a51ccef555dabaf)) +* add missing batch options catppuccin_pane{,_active}_border_style ([3ffbc37](https://github.com/catppuccin/tmux/commit/3ffbc3700b4c1c3e2c4d015c5a51ccef555dabaf)) +* escaping in options ([#298](https://github.com/catppuccin/tmux/issues/298)) ([9b57c20](https://github.com/catppuccin/tmux/commit/9b57c2002081fff8af16b878f1369d46788c0409)) +* **pomodoro_plus:** option names ([#273](https://github.com/catppuccin/tmux/issues/273)) ([51dde6e](https://github.com/catppuccin/tmux/commit/51dde6e8d4d3d8da97d915b01594a08aa4ac0cca)) +* warning `[@catppuccin](https://github.com/catppuccin)_flavour` ([#296](https://github.com/catppuccin/tmux/issues/296)) ([a71f3c0](https://github.com/catppuccin/tmux/commit/a71f3c039bed8a7c49fc390a50befec5db2c4af9)) +* warning `[@catppuccin](https://github.com/catppuccin)_window_status` ([9ee1695](https://github.com/catppuccin/tmux/commit/9ee1695d757c16e2f236858b8d3f88be9fb666fa)) + + +### Performance Improvements + +* batch tmux show ([#288](https://github.com/catppuccin/tmux/issues/288)) ([99013fa](https://github.com/catppuccin/tmux/commit/99013fafe6a98416079b3b84751f2eb540e17c79)), closes [#281](https://github.com/catppuccin/tmux/issues/281) +* batch tmux show-options ([3c6f6f2](https://github.com/catppuccin/tmux/commit/3c6f6f282b3bb17554dc2b4b80760b6507acfd65)) + +## [0.1.0](https://github.com/catppuccin/tmux/compare/v0.0.1...v0.1.0) (2024-08-04) + + +### Features + +* releases ([#260](https://github.com/catppuccin/tmux/issues/260)) ([5fbacdf](https://github.com/catppuccin/tmux/commit/5fbacdf3559cf4496eef02aead087b3bb715e570)) diff --git a/home/config/tmux/plugins/catppuccin/tmux/CONTRIBUTING.md b/home/config/tmux/plugins/catppuccin/tmux/CONTRIBUTING.md new file mode 100644 index 0000000..c86496f --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/CONTRIBUTING.md @@ -0,0 +1,40 @@ +# Contributing + +## Design + +To understand our mindset in developing this plugin and how to ensure your +changes align with that mindset, check out the "[Design Philosophy](./docs/explanation/design.md)." + +## Commit messages + +This repository uses [Conventional Commits](https://conventionalcommits.org). +Commit headers should be lowercase. Most commits should include a body that briefly +describes the motivation and content of the commit. + +### Commit types + +- `fix`: A bug fix that doesn't modify the public API +- `feat`: A code change that adds functionality +- `change`: A modification to the public API +- `deprecate`: Something in the public API has been deprecated +- `remove`: A part of the public API has been removed +- `refactor`: A code change that doesn't change behavior +- `style`: A style fix or change +- `docs`: Any change to documentation +- `revert`: A revert commit. The message should describe the reasoning and the + commit should include the `Refs:` footer with the short hashes of the commits + being reverted. +- `chore`: catch-all type + +### Breaking changes + +All breaking changes should be documented in the commit footer in the format +described by Conventional Commits. Use the `!` syntax in order to distinguish +breaking commits in the log, but include the footer to provide a better description +for the changelog generator. + +```text +feat(bar)!: foo the bars + +BREAKING CHANGE: bars are now foo'ed +``` diff --git a/home/config/tmux/plugins/catppuccin/tmux/LICENSE b/home/config/tmux/plugins/catppuccin/tmux/LICENSE new file mode 100644 index 0000000..006383b --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2021 Catppuccin + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/home/config/tmux/plugins/catppuccin/tmux/README.md b/home/config/tmux/plugins/catppuccin/tmux/README.md new file mode 100644 index 0000000..74572cb --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/README.md @@ -0,0 +1,242 @@ + +

+ Logo
+ + Catppuccin for Tmux + +

+ +

+ + + +

+ +

+ +

+ + +## Themes + +
+๐ŸŒป Latte + +![Latte Flavor Preview](./assets/latte.webp) + +
+
+๐Ÿชด Frappรฉ + +![Frappe Flavor Preview](./assets/frappe.webp) + +
+
+๐ŸŒบ Macchiato + +![Macchiato Flavor Preview](./assets/macchiato.webp) + +
+
+๐ŸŒฟ Mocha + +![Mocha Flavor Preview](./assets/mocha.webp) + +
+ +## Installation + +In order to have the icons displayed correctly please use/update your favorite +[nerd font](https://www.nerdfonts.com/font-downloads). +If you do not have a patched font installed, you can override or remove any +icon. Check the [documentation](./docs/reference/configuration.md) on the +options available. + +### Manual (Recommended) + +This method is recommended as TPM has some issues with name conflicts. + + + +1. Clone this repository to your desired location (e.g. + `~/.config/tmux/plugins/catppuccin`). + + ```bash + mkdir -p ~/.config/tmux/plugins/catppuccin + git clone -b v2.3.0 https://github.com/catppuccin/tmux.git ~/.config/tmux/plugins/catppuccin/tmux + ``` + +1. Add the following line to your `tmux.conf` file: + `run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux`. +1. Reload Tmux by either restarting or reloading with `tmux source ~/.tmux.conf`. + + +Check out what to do next in the "[Getting Started Guide](./docs/tutorials/01-getting-started.md)". + +### TPM + + + +1. Install [TPM](https://github.com/tmux-plugins/tpm) +1. Add the Catppuccin plugin: + + ```bash + set -g @plugin 'catppuccin/tmux#v2.3.0' # See https://github.com/catppuccin/tmux/tags for additional tags + # ...alongside + set -g @plugin 'tmux-plugins/tpm' + ``` + +1. (Optional) Set your preferred flavor, it defaults to `"mocha"`: + + ```bash + set -g @catppuccin_flavor 'mocha' # latte, frappe, macchiato or mocha + ``` + + + +> [!IMPORTANT] +> You may have to run `~/.config/tmux/plugins/tpm/bin/clean_plugins` +> if upgrading from an earlier version +> (especially from `v0.3.0`). + +### For TMUX versions prior to 3.2 + +This plugin uses features that were only introduced into tmux in version 3.2. +If you are using a version earlier than this, you can still have lovely +catppuccin colors, the installation method just looks a little different. + +```sh +# In your ~/.tmux.conf + +# Add the colors from the pallete. Check the themes/ directory for all options. + +# Some basic mocha colors. +set -g @ctp_bg "#24273a" +set -g @ctp_surface_1 "#494d64" +set -g @ctp_fg "#cad3f5" +set -g @ctp_mauve "#c6a0f6" +set -g @ctp_crust "#181926" + +# status line +set -gF status-style "bg=#{@ctp_bg},fg=#{@ctp_fg}" + +# windows +set -gF window-status-format "#[bg=#{@ctp_surface_1},fg=#{@ctp_fg}] ##I ##T " +set -gF window-status-current-format "#[bg=#{@ctp_mauve},fg=#{@ctp_crust}] ##I ##T " +``` + +### For TMUX versions prior to 3.6 + +This plugin can be used in conjunction with the support for tmux to +automatically report dark or light themes using hooks. You can leverage these +hooks in your tmux configuration file like so: + +```conf +set-hook -g client-dark-theme { + set -g @catppuccin_flavor "frappe" + set -g @catppuccin_reset "true" + + # NOTE: you may need to set more `@catppuccin_*` variables to fully reset + # everything. + + run ~/code/github.com/catppuccin/tmux/catppuccin.tmux +} +set-hook -g client-light-theme { + set -g @catppuccin_flavor "latte" + set -g @catppuccin_reset "true" + + # NOTE: you may need to set more `@catppuccin_*` variables to fully reset + # everything. + + run ~/code/github.com/catppuccin/tmux/catppuccin.tmux +} +``` + +The above is only possible with versions of tmux 3.6+. To replicate this +functionality with versions prior to 3.6, you can will need to set variables and +run the `cappuccin.tmux` file and trigger it yourself. If you'd like some +inspiration for how to do this, read through [the Bash code found in this Nix +function here][reload-example] which reloads Catppuccin on-demand without +relying on tmux hooks. + +[reload-example]: https://git.sr.ht/~rogeruiz/.files.nix/tree/1dedf4da47f995ec41e07d37b65008ad0f464717/item/module/tools/terminal/tmux/catppuccin/bin/default.nix "An example from a catppuccin/tmux maintainer on how to manually reload the Catppuccin configuration on macOS." + +> [!IMPORTANT] +> As mentioned in the comments in the `conf` snippet above, you may find that +> you'll need to add to the list of `@catppuccin_*` variables. Test your +> configuration by switching themes and noting what of the Tmux session isn't +> getting reset to an expected color. + +### Upgrading from v0.3 + +Breaking changes have been introduced since 0.3, to understand how to migrate +your configuration, see pinned issue [#487](https://github.com/catppuccin/tmux/issues/487). + +## Recommended Default Configuration + +This configuration shows some customisation options, that can be further +extended as desired. +This is what is used for the previews above. + +![Example configuration](./assets/mocha.webp) + +```bash +# ~/.tmux.conf + +# Options to make tmux more pleasant +set -g mouse on +set -g default-terminal "tmux-256color" + +# Configure the catppuccin plugin +set -g @catppuccin_flavor "mocha" +set -g @catppuccin_window_status_style "rounded" + +# Load catppuccin +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux +# For TPM, instead use `run ~/.tmux/plugins/tmux/catppuccin.tmux` + +# Make the status line pretty and add some modules +set -g status-right-length 100 +set -g status-left-length 100 +set -g status-left "" +set -g status-right "#{E:@catppuccin_status_application}" +set -agF status-right "#{E:@catppuccin_status_cpu}" +set -agF status-right "#{E:@catppuccin_status_ram}" +set -ag status-right "#{E:@catppuccin_status_session}" +set -ag status-right "#{E:@catppuccin_status_uptime}" +set -agF status-right "#{E:@catppuccin_status_battery}" + +run ~/.config/tmux/plugins/tmux-plugins/tmux-cpu/cpu.tmux +run ~/.config/tmux/plugins/tmux-plugins/tmux-battery/battery.tmux +# Or, if using TPM, just run TPM +``` + +## Documentation + +### Guides + +- [Getting Started](./docs/tutorials/01-getting-started.md) +- [Custom Status Line Segments](./docs/tutorials/02-custom-status.md) +- [Troubleshooting](./docs/guides/troubleshooting.md) + +### Reference + +- [Status Line](./docs/reference/status-line.md) +- [Configuration Options Reference](./docs/reference/configuration.md) +- [Tmux Configuration Showcase](https://github.com/catppuccin/tmux/discussions/317) + +## ๐Ÿ’ Thanks to + +- [Pocco81](https://github.com/Pocco81) +- [vinnyA3](https://github.com/vinnyA3) +- [rogeruiz](https://github.com/rogeruiz) +- [kales](https://github.com/kjnsn) + +  + + +

+

+

Copyright © 2021-present Catppuccin Org +

+ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/config1.png b/home/config/tmux/plugins/catppuccin/tmux/assets/config1.png new file mode 100644 index 0000000..6eede6d Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/config1.png differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/config2.png b/home/config/tmux/plugins/catppuccin/tmux/assets/config2.png new file mode 100644 index 0000000..5695890 Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/config2.png differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/config3.png b/home/config/tmux/plugins/catppuccin/tmux/assets/config3.png new file mode 100644 index 0000000..e7a5af4 Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/config3.png differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/demos/basic.conf b/home/config/tmux/plugins/catppuccin/tmux/assets/demos/basic.conf new file mode 100644 index 0000000..47d811c --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/assets/demos/basic.conf @@ -0,0 +1,13 @@ +set -g @catppuccin_flavor 'frappe' + +run "#{d:current_file}/../../catppuccin.tmux" + +# Make the status line more pleasant. +set -g status-left "" +set -g status-right '#[fg=#{@thm_crust},bg=#{@thm_teal}] session: #S ' + +# Ensure that everything on the right side of the status line +# is included. +set -g status-right-length 100 + +set -g default-shell '/opt/homebrew/bin/fish' diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/demos/basic.gif b/home/config/tmux/plugins/catppuccin/tmux/assets/demos/basic.gif new file mode 100644 index 0000000..5252409 Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/demos/basic.gif differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/demos/basic.tape b/home/config/tmux/plugins/catppuccin/tmux/assets/demos/basic.tape new file mode 100644 index 0000000..cdf2002 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/assets/demos/basic.tape @@ -0,0 +1,19 @@ +Output assets/demos/basic.gif + +Require echo +Require tmux + +Set Shell "bash" +Set FontSize 30 +Set FontFamily "SFMono Nerd Font" +Set Width 1200 +Set Height 600 + +Type "tmux -f assets/demos/basic.conf" Sleep 500ms Enter + +Sleep 3s + +Ctrl+b +Type "c" + +Sleep 5s diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/example-config.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/example-config.webp new file mode 100644 index 0000000..73d997c Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/example-config.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/frappe.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/frappe.webp new file mode 100644 index 0000000..dd7f339 Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/frappe.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/generate_preview.fish b/home/config/tmux/plugins/catppuccin/tmux/assets/generate_preview.fish new file mode 100644 index 0000000..b659dee --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/assets/generate_preview.fish @@ -0,0 +1,11 @@ +set -l flavors latte frappe macchiato mocha + +for flavor in $flavors + magick $flavor.webp -crop '1320x50+0+464' +repage $flavor-crop.webp +end + +catwalk {latte,frappe,macchiato,mocha}-crop.webp --output preview.webp --layout column + +for flavor in $flavors + rm $flavor-crop.webp +end diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/latte.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/latte.webp new file mode 100644 index 0000000..3a5fe13 Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/latte.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/macchiato.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/macchiato.webp new file mode 100644 index 0000000..f752424 Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/macchiato.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/mocha.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/mocha.webp new file mode 100644 index 0000000..49f447a Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/mocha.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/preview.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/preview.webp new file mode 100644 index 0000000..97d75de Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/preview.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/ram-example.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/ram-example.webp new file mode 100644 index 0000000..9bbf4e7 Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/ram-example.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/structure.svg b/home/config/tmux/plugins/catppuccin/tmux/assets/structure.svg new file mode 100644 index 0000000..fa0878b --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/assets/structure.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/window-basic.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/window-basic.webp new file mode 100644 index 0000000..19b5f43 Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/window-basic.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/window-none.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/window-none.webp new file mode 100644 index 0000000..cedbdec Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/window-none.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/window-rounded.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/window-rounded.webp new file mode 100644 index 0000000..9c746b1 Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/window-rounded.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/assets/window-slanted.webp b/home/config/tmux/plugins/catppuccin/tmux/assets/window-slanted.webp new file mode 100644 index 0000000..ecb751f Binary files /dev/null and b/home/config/tmux/plugins/catppuccin/tmux/assets/window-slanted.webp differ diff --git a/home/config/tmux/plugins/catppuccin/tmux/catppuccin.tmux b/home/config/tmux/plugins/catppuccin/tmux/catppuccin.tmux new file mode 100755 index 0000000..40050ba --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/catppuccin.tmux @@ -0,0 +1,7 @@ +#!/usr/bin/env bash + +# Set path of script +PLUGIN_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" + +tmux source "${PLUGIN_DIR}/catppuccin_options_tmux.conf" +tmux source "${PLUGIN_DIR}/catppuccin_tmux.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/catppuccin_options_tmux.conf b/home/config/tmux/plugins/catppuccin/tmux/catppuccin_options_tmux.conf new file mode 100644 index 0000000..2f6a484 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/catppuccin_options_tmux.conf @@ -0,0 +1,145 @@ +# All options and their defaults. +# +# This is executed separately to the main configuration +# so that options are set before parsing the rest of the config. + +# Reset everything if requested. +# +# Useful for auto switching between themes: +# +# set-hook -g client-dark-theme { +# set -g @catppuccin_flavor "frappe" +# set -g @catppuccin_reset "true" +# run ~/code/github.com/catppuccin/tmux/catppuccin.tmux +# } +# set-hook -g client-light-theme { +# set -g @catppuccin_flavor "latte" +# set -g @catppuccin_reset "true" +# run ~/code/github.com/catppuccin/tmux/catppuccin.tmux +# } +%if "#{==:#{@catppuccin_reset},true}" +set -Ugq @thm_bg +set -Ugq @thm_fg +set -Ugq @thm_rosewater +set -Ugq @thm_flamingo +set -Ugq @thm_rosewater +set -Ugq @thm_pink +set -Ugq @thm_mauve +set -Ugq @thm_red +set -Ugq @thm_maroon +set -Ugq @thm_peach +set -Ugq @thm_yellow +set -Ugq @thm_green +set -Ugq @thm_teal +set -Ugq @thm_sky +set -Ugq @thm_sapphire +set -Ugq @thm_blue +set -Ugq @thm_lavender +set -Ugq @thm_subtext_1 +set -Ugq @thm_subtext_0 +set -Ugq @thm_overlay_2 +set -Ugq @thm_overlay_1 +set -Ugq @thm_overlay_0 +set -Ugq @thm_surface_2 +set -Ugq @thm_surface_1 +set -Ugq @thm_surface_0 +set -Ugq @thm_mantle +set -Ugq @thm_crust +set -Ugq @catppuccin_window_status_style +set -Ugq @catppuccin_window_text_color +set -Ugq @catppuccin_window_number_color +set -Ugq @catppuccin_window_text +set -Ugq @catppuccin_window_number +set -Ugq @catppuccin_window_current_text_color +set -Ugq @catppuccin_window_current_number_color +set -Ugq @catppuccin_window_current_text +set -Ugq @catppuccin_window_current_number +set -Ugq @catppuccin_window_number_position +set -Ugq @catppuccin_window_flags +set -Ugq @catppuccin_window_flags_icon_last +set -Ugq @catppuccin_window_flags_icon_current +set -Ugq @catppuccin_window_flags_icon_zoom +set -Ugq @catppuccin_window_flags_icon_mark +set -Ugq @catppuccin_window_flags_icon_silent +set -Ugq @catppuccin_window_flags_icon_activity +set -Ugq @catppuccin_window_flags_icon_bell +set -Ugq @catppuccin_window_flags_icon_format +set -Ugq @catppuccin_status_left_separator +set -Ugq @catppuccin_status_middle_separator +set -Ugq @catppuccin_status_right_separator +set -Ugq @catppuccin_status_connect_separator +set -Ugq @catppuccin_status_module_text_bg +set -Ugq @catppuccin_window_current_left_separator +set -Ugq @catppuccin_window_current_middle_separator +set -Ugq @catppuccin_window_current_right_separator + +# Finally reset the reset option. +set -Ug @catppuccin_reset +%endif + +# DO NOT USE -o IN YOUR OWN CONFIGURATION +set -ogq @catppuccin_flavor "mocha" + +set -ogq @catppuccin_status_background "default" + +# Menu styling options +set -ogq @catppuccin_menu_selected_style "fg=#{@thm_fg},bold,bg=#{@thm_overlay_0}" + +# Pane styling options (DO NOT USE -o IN YOUR OWN CONFIGURATION) +set -ogq @catppuccin_pane_status_enabled "no" # set to "yes" to enable +set -ogq @catppuccin_pane_border_status "off" # set to "yes" to enable +set -ogq @catppuccin_pane_border_style "fg=#{@thm_overlay_0}" +set -ogq @catppuccin_pane_active_border_style "##{?pane_in_mode,fg=#{@thm_lavender},##{?pane_synchronized,fg=#{@thm_mauve},fg=#{@thm_lavender}}}" +set -ogq @catppuccin_pane_left_separator "โ–ˆ" +set -ogq @catppuccin_pane_middle_separator "โ–ˆ" +set -ogq @catppuccin_pane_right_separator "โ–ˆ" +set -ogq @catppuccin_pane_color "#{@thm_green}" +set -ogq @catppuccin_pane_background_color "#{@thm_surface_0}" +set -ogq @catppuccin_pane_default_text "##{b:pane_current_path}" +set -ogq @catppuccin_pane_default_fill "number" +set -ogq @catppuccin_pane_number_position "left" # right, left + +# NOTE: Changes to make the option names more intuitive and more closely follow +# the tmux naming conventions. +# @catppuccin_window_current_background -> @catppuccin_window_current_number_color +# @catppuccin_window_current_color -> @catppuccin_window_current_text_color +# @catppuccin_window_default_background -> @catppuccin_window_number_color +# @catppuccin_window_default_color -> @catppuccin_window_text_color +# @catppuccin_window_status -> @catppuccin_window_flags +# +# Removed: +# @catppuccin_window_default_fill, @catppuccin_window_current_fill +# Just set the number and text colors. + +# Window options (DO NOT USE -o IN YOUR OWN CONFIGURATION) +set -ogq @catppuccin_window_status_style "basic" # basic, rounded, slanted, custom, or none +set -ogq @catppuccin_window_text_color "#{@thm_surface_0}" +set -ogq @catppuccin_window_number_color "#{@thm_overlay_2}" +set -ogq @catppuccin_window_text " #T" +set -ogq @catppuccin_window_number "#I" +set -ogq @catppuccin_window_current_text_color "#{@thm_surface_1}" +set -ogq @catppuccin_window_current_number_color "#{@thm_mauve}" +set -ogq @catppuccin_window_current_text " #T" +set -ogq @catppuccin_window_current_number "#I" +set -ogq @catppuccin_window_number_position "left" + +# Window flags +set -ogq @catppuccin_window_flags "none" +set -ogq @catppuccin_window_flags_icon_last " ๓ฐ–ฐ" # - +set -ogq @catppuccin_window_flags_icon_current " ๓ฐ–ฏ" # * +set -ogq @catppuccin_window_flags_icon_zoom " ๓ฐŒ" # Z +set -ogq @catppuccin_window_flags_icon_mark " ๓ฐƒ€" # M +set -ogq @catppuccin_window_flags_icon_silent " ๓ฐ‚›" # ~ +set -ogq @catppuccin_window_flags_icon_activity " ๓ฑ…ซ" # # +set -ogq @catppuccin_window_flags_icon_bell " ๓ฐ‚ž" # ! +# Matches icon order when using `#F` (`#!~[*-]MZ`) +set -ogq @catppuccin_window_flags_icon_format "##{?window_activity_flag,#{E:@catppuccin_window_flags_icon_activity},}##{?window_bell_flag,#{E:@catppuccin_window_flags_icon_bell},}##{?window_silence_flag,#{E:@catppuccin_window_flags_icon_silent},}##{?window_active,#{E:@catppuccin_window_flags_icon_current},}##{?window_last_flag,#{E:@catppuccin_window_flags_icon_last},}##{?window_marked_flag,#{E:@catppuccin_window_flags_icon_mark},}##{?window_zoomed_flag,#{E:@catppuccin_window_flags_icon_zoom},} " + +# Status line options (DO NOT USE -o IN YOUR OWN CONFIGURATION) +set -ogq @catppuccin_status_left_separator "๎‚ถ" +set -ogq @catppuccin_status_middle_separator "" +set -ogq @catppuccin_status_right_separator " " +set -ogq @catppuccin_status_connect_separator "yes" # yes, no + +# Maintain backwards compatibility. Use @catppuccin_status_module_bg_color if it is set. +set -ogq @catppuccin_status_module_text_bg "#{?@catppuccin_status_module_bg_color,#{E:@catppuccin_status_module_bg_color},#{@thm_surface_0}}" diff --git a/home/config/tmux/plugins/catppuccin/tmux/catppuccin_tmux.conf b/home/config/tmux/plugins/catppuccin/tmux/catppuccin_tmux.conf new file mode 100644 index 0000000..67a5ba2 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/catppuccin_tmux.conf @@ -0,0 +1,225 @@ +source -F "#{d:current_file}/themes/catppuccin_#{@catppuccin_flavor}_tmux.conf" + +%if "#{==:#{@catppuccin_status_background},default}" + set -gF @_ctp_status_bg "#{@thm_mantle}" + set -gF status-style "bg=#{@_ctp_status_bg},fg=#{@thm_fg}" + + %hidden CTP_MESSAGE_BACKGROUND="#{@thm_overlay_0}" +%elif "#{==:#{@catppuccin_status_background},none}" + set -g status-style "default" + set -g @_ctp_status_bg "none" + + %hidden CTP_MESSAGE_BACKGROUND="default" +%else + # Treat @catppuccin_status_background as a format string. + set -gF status-style "bg=#{E:@catppuccin_status_background},fg=#{@thm_fg}" + set -gF @_ctp_status_bg "#{E:@catppuccin_status_background}" + + %hidden CTP_MESSAGE_BACKGROUND="#{E:@catppuccin_status_background}" +%endif + +source -F "#{d:current_file}/status/application.conf" +source -F "#{d:current_file}/status/battery.conf" +source -F "#{d:current_file}/status/clima.conf" +source -F "#{d:current_file}/status/cpu.conf" +source -F "#{d:current_file}/status/date_time.conf" +source -F "#{d:current_file}/status/directory.conf" +source -F "#{d:current_file}/status/gitmux.conf" +source -F "#{d:current_file}/status/host.conf" +source -F "#{d:current_file}/status/kube.conf" +source -F "#{d:current_file}/status/load.conf" +source -F "#{d:current_file}/status/pomodoro_plus.conf" +source -F "#{d:current_file}/status/ram.conf" +source -F "#{d:current_file}/status/session.conf" +source -F "#{d:current_file}/status/uptime.conf" +source -F "#{d:current_file}/status/user.conf" +source -F "#{d:current_file}/status/weather.conf" + +# messages +set -gF message-style "fg=#{@thm_teal},bg=$CTP_MESSAGE_BACKGROUND,align=centre" +set -gF message-command-style "fg=#{@thm_teal},bg=$CTP_MESSAGE_BACKGROUND,align=centre" + +# menu +%if "#{>=:#{version},3.4}" + set -gF menu-selected-style "#{E:@catppuccin_menu_selected_style}" +%endif + +# panes +set -wgF pane-active-border-style "#{E:@catppuccin_pane_active_border_style}" +set -wgF pane-border-style "#{E:@catppuccin_pane_border_style}" + +%if "#{==:#{@catppuccin_pane_status_enabled},yes}" + # "internal" variables are kept as @_ctp_p_.* + # and then unset at the end. + set -gq @_ctp_p_left "" # the content on the left, usually a separator + set -gq @_ctp_p_middle "" + set -gq @_ctp_p_right "" + set -gq @_ctp_p_number "" + set -gq @_ctp_p_text "" + + %if "#{==:#{@catppuccin_pane_default_fill},none}" + set -g @_ctp_p_left \ + "#[fg=#{@thm_surface_0},bg=default]#{@catppuccin_pane_left_separator}" + set -g @_ctp_p_middle \ + "#[fg=#{@thm_fg},bg=#{@thm_surface_0}]#{@catppuccin_pane_middle_separator}" + set -g @_ctp_p_right \ + "#[fg=#{@thm_surface_0},bg=default]#{@catppuccin_pane_right_separator}" + + set -g @_ctp_p_number \ + "#[fg=#{@thm_fg},bg=#{@thm_surface_0}]##{pane_index}" + set -g @_ctp_p_text \ + "#[fg=#{@thm_fg},bg=#{@thm_surface_0}]#{E:@catppuccin_pane_default_text}" + + %elif "#{==:#{@catppuccin_pane_default_fill},all}" + + set -g @_ctp_p_left \ + "#[fg=#{E:@catppuccin_pane_color},bg=default]#{@catppuccin_pane_left_separator}" + set -g @_ctp_p_middle \ + "#[fg=#{E:@catppuccin_pane_color},bg=#{E:@catppuccin_pane_background_color}]#{@catppuccin_pane_middle_separator}" + set -g @_ctp_p_right \ + "#[fg=#{E:@catppuccin_pane_color},bg=default]#{@catppuccin_pane_right_separator}" + + set -g @_ctp_p_number \ + "#[fg=#{E:@catppuccin_pane_background_color},bg=#{E:@catppuccin_pane_color}]##{pane_index}" + set -g @_ctp_p_text \ + "#[fg=#{E:@catppuccin_pane_background_color},bg=#{E:@catppuccin_pane_color}]#{E:@catppuccin_pane_default_text}" + + %elif "#{==:#{@catppuccin_pane_default_fill},number}" + + %if "#{==:#{@catppuccin_pane_number_position},left}" + set -g @_ctp_p_left \ + "#[fg=#{E:@catppuccin_pane_color},bg=default]#{@catppuccin_pane_left_separator}" + set -g @_ctp_p_right \ + "#[fg=#{E:@catppuccin_pane_background_color},bg=default]#{@catppuccin_pane_right_separator}" + %else + set -g @_ctp_p_left \ + "#[fg=#{E:@catppuccin_pane_background_color},bg=default]#{@catppuccin_pane_left_separator}" + set -g @_ctp_p_right \ + "#[fg=#{E:@catppuccin_pane_color},bg=default]#{@catppuccin_pane_right_separator}" + %endif + + set -g @_ctp_p_middle \ + "#[fg=#{E:@catppuccin_pane_color},bg=#{E:@catppuccin_pane_background_color}]#{@catppuccin_pane_middle_separator}" + + set -g @_ctp_p_number \ + "#[fg=#{E:@catppuccin_pane_background_color},bg=#{E:@catppuccin_pane_color}]##{pane_index}" + set -g @_ctp_p_text \ + "#[fg=#{E:@catppuccin_pane_color},bg=#{E:@catppuccin_pane_background_color}]#{E:@catppuccin_pane_default_text}" + + %endif + + %if "#{==:#{@catppuccin_pane_number_position},left}" + set -wgF pane-border-format \ + "#{E:@_ctp_p_left}#{E:@_ctp_p_number}#{E:@_ctp_p_middle} #{E:@_ctp_p_text}#{E:@_ctp_p_right}" + %else + set -wgF pane-border-format \ + "#{E:@_ctp_p_left}#{E:@_ctp_p_text} #{E:@_ctp_p_middle}#{E:@_ctp_p_number}#{E:@_ctp_p_right}" + %endif + + set -ug @_ctp_p_left + set -ug @_ctp_p_middle + set -ug @_ctp_p_right + set -ug @_ctp_p_number + set -ug @_ctp_p_text +%endif + +# popups +%if "#{>=:#{version},3.4}" + set -gF popup-style "bg=#{@thm_bg},fg=#{@thm_fg}" + set -gF popup-border-style "fg=#{@thm_surface_1}" +%endif + +%if "#{==:#{@catppuccin_window_status_style},basic}" + + set -gq @catppuccin_window_left_separator " " + set -gq @catppuccin_window_middle_separator " " + set -gq @catppuccin_window_right_separator " " + +%elif "#{==:#{@catppuccin_window_status_style},rounded}" + + set -gq @catppuccin_window_left_separator "#[fg=#{@_ctp_status_bg},reverse]๎‚ถ#[none]" + set -gq @catppuccin_window_middle_separator " " + set -gq @catppuccin_window_right_separator "#[fg=#{@_ctp_status_bg},reverse]๎‚ด#[none]" + +%elif "#{==:#{@catppuccin_window_status_style},slanted}" + + set -gq @catppuccin_window_left_separator "#[fg=#{@_ctp_status_bg},reverse]๎‚บ#[none]" + + %if "#{==:#{@catppuccin_window_number_position},left}" + set -gq @catppuccin_window_middle_separator "#[fg=#{@catppuccin_window_number_color},bg=#{@catppuccin_window_text_color}]๎‚ผ" + set -gq @catppuccin_window_current_middle_separator \ + "#[fg=#{@catppuccin_window_current_number_color},bg=#{@catppuccin_window_current_text_color}]๎‚ผ" + %else + set -gq @catppuccin_window_middle_separator " #[fg=#{@catppuccin_window_number_color},bg=#{@catppuccin_window_text_color}]๎‚บ" + set -gq @catppuccin_window_current_middle_separator \ + " #[fg=#{@catppuccin_window_current_number_color},bg=#{@catppuccin_window_current_text_color}]๎‚บ" + %endif + + set -gq @catppuccin_window_right_separator "#[fg=#{@_ctp_status_bg},reverse]โ–ˆ๎‚ผ#[none]" + +%endif + +# DO NOT USE -o IN YOUR OWN CONFIGURATION +set -ogqF @catppuccin_window_current_left_separator "#{@catppuccin_window_left_separator}" +set -ogqF @catppuccin_window_current_middle_separator "#{@catppuccin_window_middle_separator}" +set -ogqF @catppuccin_window_current_right_separator "#{@catppuccin_window_right_separator}" + +# window status +%if "#{!=:#{@catppuccin_window_status_style},none}" + set -gF window-status-activity-style "bg=#{@thm_lavender},fg=#{@thm_crust}" + set -gF window-status-bell-style "bg=#{@thm_yellow},fg=#{@thm_crust}" + + %if "#{==:#{@catppuccin_window_flags},icon}" + set -gqF @_ctp_w_flags "#{E:@catppuccin_window_flags_icon_format}" + %elif "#{==:#{@catppuccin_window_flags},text}" + set -gq @_ctp_w_flags "#F" + %else + set -gq @_ctp_w_flags "" + %endif + + set -g @_ctp_w_number_style "#[fg=#{@thm_crust},bg=#{@catppuccin_window_number_color}]" + set -g @_ctp_w_text_style "#[fg=#{@thm_fg},bg=#{@catppuccin_window_text_color}]" + %if "#{==:#{@catppuccin_window_number_position},left}" + set -gF window-status-format \ + "#{E:@_ctp_w_number_style}#{E:@catppuccin_window_left_separator}#{@catppuccin_window_number}" + set -agF window-status-format "#{E:@catppuccin_window_middle_separator}" + set -agF window-status-format \ + "#{E:@_ctp_w_text_style}#{@catppuccin_window_text}#{@_ctp_w_flags}#{E:@catppuccin_window_right_separator}" + %else + set -gF window-status-format \ + "#{E:@_ctp_w_text_style}#{E:@catppuccin_window_left_separator}#{E:@_ctp_w_text_style}#{@catppuccin_window_text}#{@_ctp_w_flags}" + set -agF window-status-format "#{E:@catppuccin_window_middle_separator}" + set -agF window-status-format \ + "#{E:@_ctp_w_number_style} #{@catppuccin_window_number}#{E:@catppuccin_window_right_separator}" + %endif + + # ======================================= + # And do the same for the current window. + # ======================================= + + set -g @_ctp_w_number_style "#[fg=#{@thm_crust},bg=#{@catppuccin_window_current_number_color}]" + set -g @_ctp_w_text_style "#[fg=#{@thm_fg},bg=#{@catppuccin_window_current_text_color}]" + %if "#{==:#{@catppuccin_window_number_position},left}" + set -gF window-status-current-format \ + "#{E:@_ctp_w_number_style}#{E:@catppuccin_window_current_left_separator}#{@catppuccin_window_current_number}" + set -agF window-status-current-format "#{E:@catppuccin_window_current_middle_separator}" + set -agF window-status-current-format \ + "#{E:@_ctp_w_text_style}#{@catppuccin_window_current_text}#{@_ctp_w_flags}#{E:@catppuccin_window_current_right_separator}" + %else + set -gF window-status-current-format \ + "#{E:@_ctp_w_text_style}#{E:@catppuccin_window_current_left_separator}#{E:@_ctp_w_text_style}#{@catppuccin_window_current_text}#{@_ctp_w_flags}" + set -agF window-status-current-format "#{E:@catppuccin_window_current_middle_separator}" + set -agF window-status-current-format \ + "#{E:@_ctp_w_number_style} #{@catppuccin_window_current_number}#{E:@catppuccin_window_current_right_separator}" + %endif + + + # Cleanup (unset) all of the internal variables. + set -ug @_ctp_w_number_style + set -ug @_ctp_w_text_style + set -ug @_ctp_w_flags +%endif + +# Mode style. This is used for copy mode highlighting to style the current selection. +set -gF mode-style "bg=#{@thm_surface_0},bold" +set -gF clock-mode-colour "#{@thm_blue}" diff --git a/home/config/tmux/plugins/catppuccin/tmux/docs/explanation/design.md b/home/config/tmux/plugins/catppuccin/tmux/docs/explanation/design.md new file mode 100644 index 0000000..60c4fd0 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/docs/explanation/design.md @@ -0,0 +1,57 @@ +## Design Philosophy + +First and foremost, this is a color scheme. Making colors work +well takes precedence over other kinds of functionality. + +### History + +This plugin kept on growing essentially because no one was there to push back on +changes that went against, for example, parts of the UNIX philosophy. This lead to +a state where there were almost an infinite number of configuration options, +and combining them in unique ways would almost certainly break something. +Maintaining the options for everyone's setup was impossible, and fixing +one bug would cause several others to appear. Eventually the addition +of more and more things that didn't relate to colors, such as status line modules, +took time away from getting the basics right. + +Moving forward, we will be trying to align with the philosophies listed below. +This is in contrast to what the plugin has historically offered in terms of functionality. + +### UNIX Philosphy + +1. Write programs that do one thing and do it well. + - Do colors, and do colors well. Other things like displaying the weather + are not the responsibility of this plugin. +1. Write programs to work together. + - The full palette is exposed as user options, allowing + easy integration with any other kind of tmux configuration. +1. Write programs to handle text streams, because that is a universal interface. + - TMUX is a text based program. Each of the palette options are strings + in user options that can be piped into other programs and options. + +### Configurability is the root of all evil + +Adopted from "[Fish Shell's design philophy](https://fishshell.com/docs/current/design.html)". + +Every configuration option in a program is a place where the program is too +stupid to figure out for itself what the user really wants, and should be +considered a failure of both the program and the programmer who implemented it. + +Rationale: Different configuration options are a nightmare to maintain, since +the number of potential bugs caused by specific configuration combinations +quickly becomes an issue. Configuration options often imply assumptions about +the code which change when reimplementing the code, causing issues with +backwards compatibility. But mostly, configuration options should be avoided +since they simply should not exist, as the program should be smart enough to do +what is best, or at least a good enough approximation of it. + +### The law of orthogonality + +The set of options that do exist should have a small set of orthogonal features. +Any situation where two options are related but not identical, one of them +should be removed, and the other should be made powerful and general enough to +handle all common use cases of either feature. + +Rationale: Related features make the configuration options larger, which makes +it harder to use. It also increases the size of the source code, making the +program harder to maintain and update. diff --git a/home/config/tmux/plugins/catppuccin/tmux/docs/guides/troubleshooting.md b/home/config/tmux/plugins/catppuccin/tmux/docs/guides/troubleshooting.md new file mode 100644 index 0000000..4479062 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/docs/guides/troubleshooting.md @@ -0,0 +1,37 @@ +# Frequently Asked Questions + +## Window Names + +By default, window names are the pane title, and the pane title is +set by the shell running in each pane. Oh My ZSH does this [automatically](https://github.com/ohmyzsh/ohmyzsh/wiki/Settings#automatic-title), +as does [fish](https://fishshell.com/docs/current/cmds/fish_title.html). + +The format string used can be changed by setting the following options: + +```bash +set -g @catppuccin_window_text "#W" +set -g @catppuccin_window_current_text "#W" +``` + +The window title is `#W`, the current path is `#{b:pane_current_path}`. A huge +amount of customisation is possible, and is explained in depth +in the "[tmux man page](https://man7.org/linux/man-pages/man1/tmux.1.html#FORMATS)". + +## Symbols are not displaying + +Make sure you have installed a [Nerd Font](https://www.nerdfonts.com/), +and that your terminal is set to use that font. + +## My options are not being applied + +Go through these steps: + +1. Completely kill tmux and restart (`killall tmux`). +1. Ensure every `@catppuccin.*` option is being set _before_ + the plugin is loaded. Loading occurs where you have `run` in your config file. +1. Double check for typos. There are two "c"s and two "p"s in "catppuccin". +1. Do not use `-o` to set options that begin with `@`. The `-o` flag means that + the option will not be set if it has already been set. You do not need this + in your config file. +1. Double check that any option that does _not_ start with `@` is set after the + plugin is loaded. diff --git a/home/config/tmux/plugins/catppuccin/tmux/docs/reference/configuration.md b/home/config/tmux/plugins/catppuccin/tmux/docs/reference/configuration.md new file mode 100644 index 0000000..c382a0c --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/docs/reference/configuration.md @@ -0,0 +1,116 @@ +## Configuration Reference + + + +This is a diagram of how the theme is split between its components. + +### Top Level Options + +| Option | Effect | +| -------------------- | ------------------------------------------------------------------------------ | +| `@catppuccin_flavor` | Sets the catppuccin flavor, one of "latte", "frappe", "macchiato", or "mocha". | + +### Status Line + +| Option | Effect | +| ----------------------------- | --------------------------------------------- | +| @catppuccin_status_background | Sets the background color of the status line. | + +- `default` will use the color from the selected theme +- `none` will make the status bar transparent +- use hex color codes for other colors or a theme color (`#{@thm_}`) + +### Window + +The plugin comes with three window styles built in, these can be customized by +setting the `@catppuccin_window_status_style` option. The default is `basic`. + +| Option | Effect | Preview | +| --------- | ------------------------------------------------------------------------ | ------------------------------------------------------ | +| `basic` | Simple styling with blocks. | ![window basic](../../assets/window-basic.webp) | +| `rounded` | Each window is separated with rounded separators. | ![window rounded style](../../assets/window-rounded.webp) | +| `slanted` | Each window is separated with slanted separators. | ![window slanted style](../../assets/window-slanted.webp) | +| `custom` | Custom separators are used. This is required to override the separators! | | +| `none` | Styling of the window status is completely disabled. | ![window no styling](../../assets/window-none.webp) | + +If you want to change the active color to something else (the default is mauve), +use the following. For example to use lavender: + +```bash +set -g @catppuccin_window_current_number_color "#{@thm_lavender}" +``` + +
+ +Customising the separators + +Add the following, +setting whatever values you'd like for the separators: + +```bash +set -g @catppuccin_window_status_style "custom" +set -g @catppuccin_window_left_separator "" +set -g @catppuccin_window_middle_separator "" +set -g @catppuccin_window_right_separator "" +``` + +
+ +### Menu + +**Set the menu selected style:** + +```sh +# Use a value compatible with the standard tmux `menu-selected-style` +set -g @catppuccin_menu_selected_style "fg=#{@thm_surface_0},bg=#{@thm_yellow}" +``` + +### All options and their defaults + +```bash +# Menu styling options +set -g @catppuccin_menu_selected_style "fg=#{@thm_fg},bold,bg=#{@thm_overlay_0}" + +# Pane styling options +set -g @catppuccin_pane_status_enabled "no" # set to "yes" to enable +set -g @catppuccin_pane_border_status "off" # set to "yes" to enable +set -g @catppuccin_pane_border_style "fg=#{@thm_overlay_0}" +set -g @catppuccin_pane_active_border_style "##{?pane_in_mode,fg=#{@thm_lavender},##{?pane_synchronized,fg=#{@thm_mauve},fg=#{@thm_lavender}}}" +set -g @catppuccin_pane_left_separator "โ–ˆ" +set -g @catppuccin_pane_middle_separator "โ–ˆ" +set -g @catppuccin_pane_right_separator "โ–ˆ" +set -g @catppuccin_pane_color "#{@thm_green}" +set -g @catppuccin_pane_background_color "#{@thm_surface_0}" +set -g @catppuccin_pane_default_text "##{b:pane_current_path}" +set -g @catppuccin_pane_default_fill "number" +set -g @catppuccin_pane_number_position "left" # right, left + +set -g @catppuccin_window_status_style "basic" # basic, rounded, slanted, custom, or none +set -g @catppuccin_window_text_color "#{@thm_surface_0}" +set -g @catppuccin_window_number_color "#{@thm_overlay_2}" +set -g @catppuccin_window_text " #T" +set -g @catppuccin_window_number "#I" +set -g @catppuccin_window_current_text_color "#{@thm_surface_1}" +set -g @catppuccin_window_current_number_color "#{@thm_mauve}" +set -g @catppuccin_window_current_text " #T" +set -g @catppuccin_window_current_number "#I" +set -g @catppuccin_window_number_position "left" +set -g @catppuccin_window_flags "none" # none, icon, or text +set -g @catppuccin_window_flags_icon_last " ๓ฐ–ฐ" # - +set -g @catppuccin_window_flags_icon_current " ๓ฐ–ฏ" # * +set -g @catppuccin_window_flags_icon_zoom " ๓ฐŒ" # Z +set -g @catppuccin_window_flags_icon_mark " ๓ฐƒ€" # M +set -g @catppuccin_window_flags_icon_silent " ๓ฐ‚›" # ~ +set -g @catppuccin_window_flags_icon_activity " ๓ฑ…ซ" # # +set -g @catppuccin_window_flags_icon_bell " ๓ฐ‚ž" # ! +# Matches icon order when using `#F` (`#!~[*-]MZ`) +set -g @catppuccin_window_flags_icon_format "##{?window_activity_flag,#{E:@catppuccin_window_flags_icon_activity},}##{?window_bell_flag,#{E:@catppuccin_window_flags_icon_bell},}##{?window_silence_flag,#{E:@catppuccin_window_flags_icon_silent},}##{?window_active,#{E:@catppuccin_window_flags_icon_current},}##{?window_last_flag,#{E:@catppuccin_window_flags_icon_last},}##{?window_marked_flag,#{E:@catppuccin_window_flags_icon_mark},}##{?window_zoomed_flag,#{E:@catppuccin_window_flags_icon_zoom},} " + +# Status line options +set -g @catppuccin_status_left_separator "๎‚ถ" +set -g @catppuccin_status_middle_separator "" +set -g @catppuccin_status_right_separator "โ–ˆ" +set -g @catppuccin_status_connect_separator "yes" # yes, no +set -g @catppuccin_status_fill "icon" +set -g @catppuccin_status_module_bg_color "#{@thm_surface_0}" +``` diff --git a/home/config/tmux/plugins/catppuccin/tmux/docs/reference/status-line.md b/home/config/tmux/plugins/catppuccin/tmux/docs/reference/status-line.md new file mode 100644 index 0000000..40c8be1 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/docs/reference/status-line.md @@ -0,0 +1,260 @@ +## Using the theme's built-in status modules + +To use the theme's built in status modules, set the `status-left` and +`status-right` tmux options _after_ the plugin has been loaded with `run`. + +The tmux status line modules are set as variables and prefixed with `@catppuccin_status_`. + +To use the `application` and `session` modules on the right and have nothing on +the left: + +```sh +set -g status-right-length 100 + +set -g status-right "#{E:@catppuccin_status_application}#{E:@catppuccin_status_session}" +set -g status-left "" +``` +Some notes about expanding options when setting the status line: +* Options are expanded as format strings by placing `E:` before the option name. +* When a module status string contains a reference to another variable, you have to add the `-F` flag that treats the value passed as a format string that is immediately expanded, that is use `set -gF` (see tmux [`set-option`](https://man.openbsd.org/OpenBSD-current/man1/tmux.1#set-option) man page). +* Example for such a case is the [battery](#battery-module) module below, where the status contains the format string `#{battery_percentage}` that needs to be further expanded. + +## Customizing modules + +Every module supports the following overrides: + +### Override the specific module icon + +```sh +set -g @catppuccin_[module_name]_icon "icon" +``` + +### Override the specific module color + +```sh +set -g @catppuccin_[module_name]_color "color" +``` + +### Override the specific module text + +```sh +set -g @catppuccin_[module_name]_text "text" +``` + +### Override the specific module's background color + +```sh +set -g @catppuccin_status_[module_name]_bg_color "#{@thm_surface_0}" +``` + +### Removing a specific module option + +```sh +set -g @catppuccin_[module_name]_[option] "" +``` + +This is for the situation where you want to remove the icon from a module. +For example: + +```sh +set -g @catppuccin_date_time_icon "" +``` + +### Notes for TPM users + +Make sure you load the catppuccin theme prior to setting the status-left and/or +status-* options. This ensures the catppuccin options (such as colors and +status modules) are defined so they can then be used. + +After status-left and/or status-right have been set, make sure to run TPM to load +the modules. This runs any plugins that may replace text in the status line. + +```bash +# load catppuccin theme ... +run '~/.config/tmux/plugins/tmux/catppuccin.tmux' # or where this file is located on your machine + +# ... and then set status-left & status-right ... +set -g status-left "#{E:@catppuccin_status_session}" + +set -g status-right "#{E:@catppuccin_status_[module_name]}" +set -ag status-right "#{E:@catppuccin_status_[module_name]}" +set -agF status-right "#{E:@catppuccin_status_[module_name]}" + +# ... and finally start TPM +set -g @plugin 'tmux-plugins/tpm' +run '~/.tmux/plugins/tpm/tpm' +``` + +## Battery module + +**Requirements:** This module depends on [tmux-battery](https://github.com/tmux-plugins/tmux-battery/tree/master). + +**Install:** The preferred way to install tmux-battery is using [TPM](https://github.com/tmux-plugins/tpm). + +**Configure:** + +```sh +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +set -agF status-right "#{E:@catppuccin_status_battery}" + +set -g @plugin 'tmux-plugins/tmux-battery' +run '~/.tmux/plugins/tpm/tpm' +``` + +## CPU module + +**Requirements:** This module depends on [tmux-cpu](https://github.com/tmux-plugins/tmux-cpu/tree/master). + +**Install:** The preferred way to install tmux-cpu is using [TPM](https://github.com/tmux-plugins/tpm). + +**Configure:** + +```sh +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +set -agF status-right "#{E:@catppuccin_status_cpu}" + +set -g @plugin 'tmux-plugins/tmux-cpu' +run '~/.tmux/plugins/tpm/tpm' +``` + +## RAM module + +**Requirements:** This module depends on [tmux-cpu](https://github.com/tmux-plugins/tmux-cpu/tree/master). + +**Install:** The preferred way to install tmux-cpu is using [TPM](https://github.com/tmux-plugins/tpm). + +**Configure:** + +```sh +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +set -agF status-right "#{E:@catppuccin_status_ram}" + +set -g @plugin 'tmux-plugins/tmux-cpu' +run '~/.tmux/plugins/tpm/tpm' +``` + +## Weather modules + +### tmux-weather + +**Requirements:** This module depends on [tmux-weather](https://github.com/xamut/tmux-weather). + +**Install:** The preferred way to install tmux-weather is using [TPM](https://github.com/tmux-plugins/tpm). + +**Configure:** + +```sh +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +set -agF status-right "#{E:@catppuccin_status_weather}" + +set -g @plugin 'xamut/tmux-weather' +run '~/.tmux/plugins/tpm/tpm' +``` + +### tmux-clima + +**Requirements:** This module depends on [tmux-clima](https://github.com/vascomfnunes/tmux-clima). + +**Install:** The preferred way to install tmux-clima is using [TPM](https://github.com/tmux-plugins/tpm). + +**Configure:** + +```sh +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +set -agF status-right "#{E:@catppuccin_status_clima}" + +set -g @plugin 'vascomfnunes/tmux-clima' +run '~/.tmux/plugins/tpm/tpm' +``` + +## Load module + +**Configure:** + +```sh +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +set -agF status-right "#{E:@catppuccin_status_load}" +``` + +## Gitmux module + +**Requirements:** This module depends on [gitmux](https://github.com/arl/gitmux). + +**Install:** To install gitmux, follow the instructions in the [gitmux documentation](https://github.com/arl/gitmux/blob/main/README.md#installing). + +**Configure:** + +Add the gitmux module to the status modules list. + +```sh +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +set -agF status-right "#{@catppuccin_status_gitmux}" +``` + +Follow the instructions in the [gitmux documentation](https://github.com/arl/gitmux/blob/main/README.md#customizing) +to create a gitmux config file. The gitmux plugin expects a file to be present +at `~/.gitmux.conf`. + +Add the following to your `~/.gitmux.conf` so that it uses catppuccin colors: + +```yaml +tmux: + styles: + clear: "#[fg=#{@thm_fg}]" + state: "#[fg=#{@thm_red},bold]" + branch: "#[fg=#{@thm_fg},bold]" + remote: "#[fg=#{@thm_teal}]" + divergence: "#[fg=#{@thm_fg}]" + staged: "#[fg=#{@thm_green},bold]" + conflict: "#[fg=#{@thm_red},bold]" + modified: "#[fg=#{@thm_yellow},bold]" + untracked: "#[fg=#{@thm_mauve},bold]" + stashed: "#[fg=#{@thm_blue},bold]" + clean: "#[fg=#{@thm_rosewater},bold]" + insertions: "#[fg=#{@thm_green}]" + deletions: "#[fg=#{@thm_red}]" +``` + +## Pomodoro module + +**Requirements:**: This module depends on [tmux-pomodoro-plus](https://github.com/olimorris/tmux-pomodoro-plus/tree/main). + +**Install:**: The preferred way to install tmux-pomodoro-plus is using [TPM](https://github.com/tmux-plugins/tpm). + +**Configure:** + +```sh +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +set -agF status-right "#{E:@catppuccin_status_pomodoro_plus}" + +set -g @plugin 'olimorris/tmux-pomodoro-plus' +run '~/.tmux/plugins/tpm/tpm' +``` + +## Kube module + +**Requirements:** This module depends on [tmux-kubectx](https://github.com/tony-sol/tmux-kubectx). + +**Install:** The preferred way to install tmux-kubectx is using [TPM](https://github.com/tmux-plugins/tpm). + +**Configure:** + +```sh +set -g @catppuccin_kube_context_color "#{@thm_red}" +set -g @catppuccin_kube_namespace_color "#{@thm_sky}" + +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +set -agF status-right "#{E:@catppuccin_status_kube}" + +set -g @plugin 'tony-sol/tmux-kubectx' +run '~/.tmux/plugins/tpm/tpm' +``` diff --git a/home/config/tmux/plugins/catppuccin/tmux/docs/tutorials/01-getting-started.md b/home/config/tmux/plugins/catppuccin/tmux/docs/tutorials/01-getting-started.md new file mode 100644 index 0000000..5694094 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/docs/tutorials/01-getting-started.md @@ -0,0 +1,72 @@ +Want to install the color scheme and make tmux pastel? Great! Here's how. + +## Step 1: Clone this repository + + +```bash +mkdir -p ~/.config/tmux/plugins/catppuccin +git clone -b v2.3.0 https://github.com/catppuccin/tmux.git ~/.config/tmux/plugins/catppuccin/tmux +``` + + +## Step 2: Edit your tmux configuration file + +Using your favourite editor, edit the file `~/.tmux.conf`. + +It should look like this: + +```bash +set -g @catppuccin_flavor 'mocha' + +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux +``` + +This will load the catppuccin plugin and apply the defaults. +To apply the changes to your configuration file, exit tmux completely +and start it again. You can also run `tmux source ~/.tmux.conf`, but this may +not work as well when changing options. + +## Step 3: Customize + +The default configuration looks a little bland. Let's change it to +be a bit more colorful. Edit your tmux config again so it looks like this. + +```bash +# Pick a softer palette. +set -g @catppuccin_flavor 'frappe' + +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux + +# Make the status line more pleasant. +set -g status-left "" +set -g status-right '#[fg=#{@thm_crust},bg=#{@thm_teal}] session: #S ' + +# Ensure that everything on the right side of the status line +# is included. +set -g status-right-length 100 +``` + +There is some new stuff here. Firstly, everything is documented in +the "[tmux man page](https://man7.org/linux/man-pages/man1/tmux.1.html)". +Go check it out if anything is unclear. The lines `set -g ...` are setting +"options". The `-g` means that the option is global, so it applies everywhere. +When an option name begins with `@`, then it is a "user" option and has no +effect on tmux itself. This is used to essentially set global variables. + +Three options are set that control how tmux looks, `status-left`, +`status-right`, and `status-right-length`. These options are documented +in the man page, but the tl;dr is that they control what appears on the left +and right of the status line. + +The `#[]` syntax is an embedded style, similar to inline css. +`fg=#{@thm_crust}` says "make the text the crust color". `@thm_crust` is a +user option set by the plugin. It is created by the line +`run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux`, so if you try +and use colors before that line, it won't work. The `#S` is a special sequence +that tmux replaces with the current session name. There are a long, long +"[list of special sequences](https://man7.org/linux/man-pages/man1/tmux.1.html#FORMATS)" +that tmux can replace. + +If everything is working right, your version should look like this: + +![Demonstration of basic configuration](../../assets/demos/basic.gif) diff --git a/home/config/tmux/plugins/catppuccin/tmux/docs/tutorials/02-custom-status.md b/home/config/tmux/plugins/catppuccin/tmux/docs/tutorials/02-custom-status.md new file mode 100644 index 0000000..7ecc4ef --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/docs/tutorials/02-custom-status.md @@ -0,0 +1,41 @@ +# User Defined Status Line Modules + +To create your own status line module that uses the catppuccin theme, +all you need to do is add it to the `status-left` or `status-right` options. + +You can add arbitrary things to the status line like so: + +```sh +# ~/.tmux.conf + +set -agF status-right "#[fg=#{@thm_crust},bg=#{@thm_teal}] ##H " +``` + +This will append the current hostname (`#H`) to the status line with a teal +background and dark black text. + +You can also use icons for styling, for example to show the used memory percentage +on MacOS: + +```sh +set -g status-right "#[bg=#{@thm_flamingo},fg=#{@thm_crust}]#[reverse]๎‚ถ#[noreverse]๓ฑ€™ " +set -ag status-right "#[fg=#{@thm_fg},bg=#{@thm_mantle}] #(memory_pressure | awk '/percentage/{print $5}') " +``` + +![Example of the custom ram module](../../assets/ram-example.webp) + +To use the status module formatting that catppuccin uses, do the following: + +```sh +# In ~/.tmux.conf, before the catppuccin plugin has been loaded. + +%hidden MODULE_NAME="my_custom_module" + +set -g "@catppuccin_${MODULE_NAME}_icon" "๏†ฎ " +set -gF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_pink}" +set -g "@catppuccin_${MODULE_NAME}_text" "#{pane_current_command}" + +source "/utils/status_module.conf" + +set -g status-right "#{E:@catppuccin_status_application}#{E:@catppuccin_status_my_custom_module}" +``` diff --git a/home/config/tmux/plugins/catppuccin/tmux/docs/tutorials/03-resetting-theme.md b/home/config/tmux/plugins/catppuccin/tmux/docs/tutorials/03-resetting-theme.md new file mode 100644 index 0000000..7e9ffa5 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/docs/tutorials/03-resetting-theme.md @@ -0,0 +1,216 @@ +# Changing the flavor of the theme by resetting + +To reset the colors colors in your status line, you can perform a reset of all +the options associated with the styling of the Tmux-line. This is done by +setting a global option called `@catppuccin_reset` to `true. + +
+ +A list of all the options that our @catppuccin_reset option resets + +```txt +@thm_bg +@thm_fg +@thm_rosewater +@thm_flamingo +@thm_rosewater +@thm_pink +@thm_mauve +@thm_red +@thm_maroon +@thm_peach +@thm_yellow +@thm_green +@thm_teal +@thm_sky +@thm_sapphire +@thm_blue +@thm_lavender +@thm_subtext_1 +@thm_subtext_0 +@thm_overlay_2 +@thm_overlay_1 +@thm_overlay_0 +@thm_surface_2 +@thm_surface_1 +@thm_surface_0 +@thm_mantle +@thm_crust +@catppuccin_window_status_style +@catppuccin_window_text_color +@catppuccin_window_number_color +@catppuccin_window_text +@catppuccin_window_number +@catppuccin_window_current_text_color +@catppuccin_window_current_number_color +@catppuccin_window_current_text +@catppuccin_window_current_number +@catppuccin_window_number_position +@catppuccin_window_flags +@catppuccin_window_flags_icon_last +@catppuccin_window_flags_icon_current +@catppuccin_window_flags_icon_zoom +@catppuccin_window_flags_icon_mark +@catppuccin_window_flags_icon_silent +@catppuccin_window_flags_icon_activity +@catppuccin_window_flags_icon_bell +@catppuccin_window_flags_icon_format +@catppuccin_status_left_separator +@catppuccin_status_middle_separator +@catppuccin_status_right_separator +@catppuccin_status_connect_separator +@catppuccin_status_module_text_bg +@catppuccin_window_current_left_separator +@catppuccin_window_current_middle_separator +@catppuccin_window_current_right_separator +``` + +
+ +All of these Tmux options above are unset, **with the `-U` flag**, when the +plugin is called with the option named `@catppuccin_reset` with a value of +`true`. Due to _the way options are set within the plugin_, **with the `-o` +flag**, all options set by the user will be reset to plugins original default +values. _This means that if you have set **any** custom options, you **may** +lose your updates and **will need to run the plugin again after setting your +custom options**_. + +> [!TIP] +> Trying running the reset yourself right now and note what breaks for your +> custom setup. That's one good way to experience what's being described above +> locally on your machine. + +This feature is the most useful for auto-switching between the theme's flavor. +It's also useful for contributing or developing the plugin locally as well. + +## Minimal example of resetting the flavor + +If you're using all the defaults of Catppuccin Tmux, you will only have to worry +about setting the flavor when setting the `@catppuccin_reset` option to `true`. + +```sh +# somewhere in a Tmux configuration file that will be sourced specifically for +# reloading `catppuccin/tmux`. +set -g @catppuccin_flavor "latte" +set -g @catppuccin_reset "true" +run /path/to/catppuccin/tmux/catppuccin.tmux +``` + +> [!NOTE] +> Your path above, the line starting with `run ...`, will need to be updated to +> where ever the `catpuccin.tmux` file is located on your system. + +## Custom example of resetting the flavor + +If you're customizing any of the settings that get reset in the list above, you +must set set options you're customizing along with any dependent options _that +aren't necessary_ when configuring the theme for only a single flavor. + +Like in the minimal example, you will set your flavor and also reset the plugin. + +```sh +# somewhere in a Tmux configuration file that will be sourced specifically for +# reloading `catppuccin/tmux`. +set -g @catppuccin_flavor "latte" +set -g @catppuccin_reset "true" +run /path/to/catppuccin/tmux/catppuccin.tmux +# we're not done yet! +``` + +But right afterwards, you'll have to set your customized options both before and +after you `run ...` the plugin. _This does mean running the plugin twice in +rapid succession_. This is due to a limitation of Tmux and how the plugin is +designed to be customizable and also ergonomic to ease with minimal +configuration. + +```sh +# somewhere in a Tmux configuration file that will be sourced specifically for +# reloading `catppuccin/tmux`. +set -g @catppuccin_flavor "mocha" +set -g @catppuccin_reset "true" +run /path/to/catppuccin/tmux/catppuccin.tmux + +# right after the initial reset call. +set -g @catppuccin_flavor "mocha" +set -g @catppuccin_window_status_style "basic" +set -g @catppuccin_window_text " #W" +set -g @catppuccin_window_number "#I" +set -g @catppuccin_window_current_text " #W" +set -g @catppuccin_window_current_number "#I" +set -g @catppuccin_pane_status_enabled "yes" +set -g @catppuccin_pane_border_status "yes" +set -g @catppuccin_window_number_position "right" +set -g @catppuccin_window_current_text "#{pane_current_path}" +set -g @catppuccin_pane_left_separator "โ–“" +set -g @catppuccin_pane_middle_separator "โ–“" +set -g @catppuccin_pane_right_separator "โ–“" +set -g @catppuccin_status_left_separator "โ–“" +set -g @catppuccin_status_middle_separator "โ–“" +set -g @catppuccin_status_right_separator "โ–“" +set -g @catppuccin_status_right_separator_inverse "no" +set -g @catppuccin_status_connect_separator "yes" +set -g @catppuccin_window_status_enable "yes" +set -g @catppuccin_status_fill "icon" +set -g @catppuccin_window_flags "icon" +set -g @catppuccin_application_icon " ๓ฐฃ† " +set -g @catppuccin_session_icon " ๏’‰ " +set -g @catppuccin_window_text_color "#{@thm_surface_0}" +set -g @catppuccin_window_number_color "#{@thm_overlay_2}" +set -g @catppuccin_window_current_text_color "#{@thm_surface_1}" +set -g @catppuccin_window_current_number_color "#{@thm_mauve}" +set -g @catppuccin_status_module_bg_color "#{@thm_surface_0}" +set -g @catppuccin_status_application_icon_fg "#{E:@thm_crust}" +set -g @catppuccin_status_application_text_fg "#{E:@thm_fg}" +set -g @catppuccin_application_color "#{E:@thm_maroon}" +set -g @catppuccin_status_session_icon_fg "#{E:@thm_crust}" +set -g @catppuccin_status_session_text_fg "#{E:@thm_fg}" +set -g @catppuccin_session_color "#{?client_prefix,#{E:@thm_red},#{E:@thm_green}}" +set -g @catppuccin_status_module_text_bg "#{?@catppuccin_status_module_bg_color,#{E:@catppuccin_status_module_bg_color},#{@thm_surface_0}}" +run /path/to/catppuccin/tmux/catppuccin.tmux +``` + +Notice that above there are certain lines that are _being set that aren't +usually set initially_. Some of these options are set within the file named +`utils/status_module.conf`, for example. While some are set in the other parts +of the plugin's configuration. This is due to the colors being unset and then +rest to the defaults **because you can't reset this plugin without also running +the default configuration options too**. _These options are highlighted below in +a smaller snippet_. These specific options aren't usually set when configuring +the plugin for a single flavor. Due to how options are reset and then again +immediately set in the `catppuccin_options_tmux.conf` file & all options will be +set to their defaults which aren't going to be what you've customized. + +```sh +# here's some options extracted from the example above which must be set again +# after the reset that you probably would not have to set if you're using the +# reset functionality. +set -g @catppuccin_window_text_color "#{@thm_surface_0}" +set -g @catppuccin_window_number_color "#{@thm_overlay_2}" +set -g @catppuccin_window_current_text_color "#{@thm_surface_1}" +set -g @catppuccin_window_current_number_color "#{@thm_mauve}" +set -g @catppuccin_status_module_bg_color "#{@thm_surface_0}" +set -g @catppuccin_status_application_icon_fg "#{E:@thm_crust}" +set -g @catppuccin_status_application_text_fg "#{E:@thm_fg}" +set -g @catppuccin_application_color "#{E:@thm_maroon}" +set -g @catppuccin_status_session_icon_fg "#{E:@thm_crust}" +set -g @catppuccin_status_session_text_fg "#{E:@thm_fg}" +set -g @catppuccin_session_color "#{?client_prefix,#{E:@thm_red},#{E:@thm_green}}" +set -g @catppuccin_status_module_text_bg "#{?@catppuccin_status_module_bg_color,#{E:@catppuccin_status_module_bg_color},#{@thm_surface_0}}" +``` + +> [!NOTE] +> See the `@catppuccin_status_module_bg_color` and other color options such as +> `@catppuccin_application_color` and others have to be set due to the how the +> plugin resets all the values listed at the top of this document. + +## You should now know how to reset the flavor using Tmux configuration files + +Thanks for reading this far. If there's any questions or concerns please reach +out to the community in our [Discord server][discord] or by creating an issue on [GitHub][github]. + +Hopefully after reading this you've got a much better understanding of both how +to reset the flavor for `catppuccin/tmux` and[the configuration][internal] for this plugin. + +[discord]: https://discord.com/servers/catppuccin-907385605422448742 "The official Catppuccin Discord server" +[github]: https://github.com/catppuccin/tmux/issues/new/choose "This project's GitHub issue type chooser page" +[internal]: ../reference/configuration.md "Our internal configuration document for this plugin" diff --git a/home/config/tmux/plugins/catppuccin/tmux/renovate.json b/home/config/tmux/plugins/catppuccin/tmux/renovate.json new file mode 100644 index 0000000..a222000 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/renovate.json @@ -0,0 +1,6 @@ +{ + "$schema": "https://docs.renovatebot.com/renovate-schema.json", + "extends": [ + "local>catppuccin/renovate-config" + ] +} diff --git a/home/config/tmux/plugins/catppuccin/tmux/run_tests.sh b/home/config/tmux/plugins/catppuccin/tmux/run_tests.sh new file mode 100755 index 0000000..2fb6a0b --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/run_tests.sh @@ -0,0 +1,15 @@ +#!/usr/bin/env bash + +set -Eeuo pipefail + +script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) + +"${script_dir}"/tests/harness.sh --test "${script_dir}"/tests/default_options.sh --expected "${script_dir}"/tests/default_options_expected.txt "$@" +"${script_dir}"/tests/harness.sh --test "${script_dir}"/tests/window_status_styling.sh --expected "${script_dir}"/tests/window_status_styling_expected.txt "$@" + +"${script_dir}"/tests/harness.sh --test "${script_dir}"/tests/application_module.sh --expected "${script_dir}"/tests/application_module_expected.txt "$@" +"${script_dir}"/tests/harness.sh --test "${script_dir}"/tests/battery_module.sh --expected "${script_dir}"/tests/battery_module_expected.txt "$@" +"${script_dir}"/tests/harness.sh --test "${script_dir}"/tests/cpu_module.sh --expected "${script_dir}"/tests/cpu_module_expected.txt "$@" +"${script_dir}"/tests/harness.sh --test "${script_dir}"/tests/load_module.sh --expected "${script_dir}"/tests/load_module_expected.txt "$@" +"${script_dir}"/tests/harness.sh --test "${script_dir}"/tests/pane_styling.sh --expected "${script_dir}"/tests/pane_styling_expected.txt "$@" +"${script_dir}"/tests/harness.sh --test "${script_dir}"/tests/ram_module.sh --expected "${script_dir}"/tests/ram_module_expected.txt "$@" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/application.conf b/home/config/tmux/plugins/catppuccin/tmux/status/application.conf new file mode 100644 index 0000000..16753ed --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/application.conf @@ -0,0 +1,8 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="application" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๏†ฎ " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_maroon}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " #{pane_current_command}" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/battery.conf b/home/config/tmux/plugins/catppuccin/tmux/status/battery.conf new file mode 100644 index 0000000..090bb73 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/battery.conf @@ -0,0 +1,22 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="battery" + +set -ogq @batt_icon_charge_tier8 "๓ฐน" +set -ogq @batt_icon_charge_tier7 "๓ฐ‚" +set -ogq @batt_icon_charge_tier6 "๓ฐฟ" +set -ogq @batt_icon_charge_tier5 "๓ฐพ" +set -ogq @batt_icon_charge_tier4 "๓ฐฝ" +set -ogq @batt_icon_charge_tier3 "๓ฐผ" +set -ogq @batt_icon_charge_tier2 "๓ฐป" +set -ogq @batt_icon_charge_tier1 "๓ฐบ" +set -ogq @batt_icon_status_charged "๓ฐšฅ" +set -ogq @batt_icon_status_charging "๓ฐ‚„" +set -ogq @batt_icon_status_discharging "๓ฐ‚ƒ" +set -ogq @batt_icon_status_unknown "๓ฐ‚‘" +set -ogq @batt_icon_status_attached "๓ฑˆ‘" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "#{l:#{battery_icon}} " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_lavender}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " #{l:#{battery_percentage}}" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/clima.conf b/home/config/tmux/plugins/catppuccin/tmux/status/clima.conf new file mode 100644 index 0000000..36900d6 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/clima.conf @@ -0,0 +1,9 @@ +# vim:set ft=tmux: +# Requires https://github.com/vascomfnunes/tmux-clima +%hidden MODULE_NAME="clima" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๏‹‰ " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_yellow}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " #{l:#{clima}}" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/cpu.conf b/home/config/tmux/plugins/catppuccin/tmux/status/cpu.conf new file mode 100644 index 0000000..ecae5c4 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/cpu.conf @@ -0,0 +1,18 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="cpu" + +set -ogq @cpu_low_fg_color "#{E:@thm_fg}" +set -ogq @cpu_medium_fg_color "#{E:@thm_fg}" +set -ogq @cpu_high_fg_color "#{E:@thm_crust}" + +set -ogq @cpu_low_bg_color "#{E:@catppuccin_status_module_text_bg}" +set -ogq @cpu_medium_bg_color "#{E:@catppuccin_status_module_text_bg}" +set -ogq @cpu_high_bg_color "#{E:@thm_red}" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๏‹› " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_yellow}" +set -ogq "@catppuccin_status_${MODULE_NAME}_text_fg" "#{l:#{cpu_fg_color}}" +set -ogq "@catppuccin_status_${MODULE_NAME}_text_bg" "#{l:#{cpu_bg_color}}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " #{l:#{cpu_percentage}}" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/date_time.conf b/home/config/tmux/plugins/catppuccin/tmux/status/date_time.conf new file mode 100644 index 0000000..7d09495 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/date_time.conf @@ -0,0 +1,8 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="date_time" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๓ฐƒฐ " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_sapphire}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " %Y-%m-%d %H:%M" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/directory.conf b/home/config/tmux/plugins/catppuccin/tmux/status/directory.conf new file mode 100644 index 0000000..55dacd1 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/directory.conf @@ -0,0 +1,8 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="directory" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๏ป " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_rosewater}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " #{b:pane_current_path}" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/gitmux.conf b/home/config/tmux/plugins/catppuccin/tmux/status/gitmux.conf new file mode 100644 index 0000000..233ab0e --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/gitmux.conf @@ -0,0 +1,9 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="gitmux" + +# Requires https://github.com/arl/gitmux +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๓ฐŠข " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_teal}" +set -gq "@catppuccin_${MODULE_NAME}_text" ' #(gitmux -cfg $HOME/.gitmux.conf "#{pane_current_path}")' + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/host.conf b/home/config/tmux/plugins/catppuccin/tmux/status/host.conf new file mode 100644 index 0000000..c78c1a9 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/host.conf @@ -0,0 +1,8 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="host" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๓ฐ’‹ " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_mauve}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " #H" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/kube.conf b/home/config/tmux/plugins/catppuccin/tmux/status/kube.conf new file mode 100644 index 0000000..8ca1e9e --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/kube.conf @@ -0,0 +1,13 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="kube" + +# Requires https://github.com/jonmosco/kube-tmux + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๓ฑƒพ " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_blue}" +set -ogqF "@catppuccin_kube_context_color" "#{E:@thm_red}" +set -ogqF "@catppuccin_kube_namespace_color" "#{E:@thm_sky}" +set -ogq "@catppuccin_${MODULE_NAME}_text" \ + " #{l:#[fg=#{@catppuccin_kube_context_color}]#{kubectx_context}#[fg=default]:#[fg=#{@catppuccin_kube_namespace_color}]#{kubectx_namespace}}" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/load.conf b/home/config/tmux/plugins/catppuccin/tmux/status/load.conf new file mode 100644 index 0000000..0cb6a96 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/load.conf @@ -0,0 +1,8 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="load" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๓ฐŠš " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_blue}" +set -ogq "@catppuccin_${MODULE_NAME}_text" "#{l:#(uptime | awk '{split(substr($0, index($0, \"load\")), a, \":\"); print a[2]\}}')" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/pomodoro_plus.conf b/home/config/tmux/plugins/catppuccin/tmux/status/pomodoro_plus.conf new file mode 100644 index 0000000..bc17e26 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/pomodoro_plus.conf @@ -0,0 +1,9 @@ +# vim:set ft=tmux: +# Requires https://github.com/olimorris/tmux-pomodoro-plus +%hidden MODULE_NAME="pomodoro_plus" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๎€ " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_peach}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " #{l:#{pomodoro_status}}" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/ram.conf b/home/config/tmux/plugins/catppuccin/tmux/status/ram.conf new file mode 100644 index 0000000..a423bab --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/ram.conf @@ -0,0 +1,18 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="ram" + +set -ogq @ram_low_fg_color "#{E:@thm_fg}" +set -ogq @ram_medium_fg_color "#{E:@thm_fg}" +set -ogq @ram_high_fg_color "#{E:@thm_crust}" + +set -ogq @ram_low_bg_color "#{E:@catppuccin_status_module_text_bg}" +set -ogq @ram_medium_bg_color "#{E:@catppuccin_status_module_text_bg}" +set -ogq @ram_high_bg_color "#{E:@thm_red}" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๎ฟ… " +set -ogqF "@catppuccin_${MODULE_NAME}_color" "#{E:@thm_yellow}" +set -ogq "@catppuccin_status_${MODULE_NAME}_text_fg" "#{l:#{ram_fg_color}}" +set -ogq "@catppuccin_status_${MODULE_NAME}_text_bg" "#{l:#{ram_bg_color}}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " #{l:#{ram_percentage}}" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/session.conf b/home/config/tmux/plugins/catppuccin/tmux/status/session.conf new file mode 100644 index 0000000..50f878d --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/session.conf @@ -0,0 +1,8 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="session" + +set -ogq "@catppuccin_${MODULE_NAME}_icon" "๎ž• " +set -ogq "@catppuccin_${MODULE_NAME}_color" "#{?client_prefix,#{E:@thm_red},#{E:@thm_green}}" +set -ogq "@catppuccin_${MODULE_NAME}_text" " #S" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/uptime.conf b/home/config/tmux/plugins/catppuccin/tmux/status/uptime.conf new file mode 100644 index 0000000..c86787f --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/uptime.conf @@ -0,0 +1,8 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="uptime" + +set -ogq @catppuccin_uptime_icon "๓ฐ”Ÿ " +set -ogqF @catppuccin_uptime_color "#{E:@thm_sapphire}" +set -ogq @catppuccin_uptime_text " #(uptime | sed 's/^[^,]*up *//; s/, *[[:digit:]]* user.*//; s/ day.*, */d /; s/ hr\\(s*\\).*/h/; s/ min\\(s*\\).*/m/; s/ sec\\(s*\\).*/s/; s/\\([0-9]\\{1,2\\}\\):\\([0-9]\\{1,2\\}\\)/\\1h \\2m/;')" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/user.conf b/home/config/tmux/plugins/catppuccin/tmux/status/user.conf new file mode 100644 index 0000000..85e6130 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/user.conf @@ -0,0 +1,8 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="user" + +set -ogq @catppuccin_user_icon "๏€‡ " +set -ogqF @catppuccin_user_color "#{E:@thm_sky}" +set -ogq @catppuccin_user_text " #(whoami)" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/status/weather.conf b/home/config/tmux/plugins/catppuccin/tmux/status/weather.conf new file mode 100644 index 0000000..b55146c --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/status/weather.conf @@ -0,0 +1,10 @@ +# vim:set ft=tmux: +%hidden MODULE_NAME="weather" + +# Requires https://github.com/xamut/tmux-weather. + +set -ogq @catppuccin_weather_icon "๏‹‰ " +set -ogqF @catppuccin_weather_color "#{E:@thm_yellow}" +set -ogq @catppuccin_weather_text " #{l:#{weather}}" + +source -F "#{d:current_file}/../utils/status_module.conf" diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/application_module.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/application_module.sh new file mode 100644 index 0000000..8159220 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/application_module.sh @@ -0,0 +1,14 @@ +#!/usr/bin/env bash + +script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) +# shellcheck disable=SC1091 +source "${script_dir}/helpers.sh" + +# Tests that the default options are set correctly +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option @catppuccin_status_application | grep -q "@thm_" && + echo "@catppuccin_status_application did not expand all colors" + +print_option @catppuccin_status_application | sed -E 's/(bash|fish|zsh)//' diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/application_module_expected.txt b/home/config/tmux/plugins/catppuccin/tmux/tests/application_module_expected.txt new file mode 100644 index 0000000..75f4082 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/application_module_expected.txt @@ -0,0 +1 @@ +@catppuccin_status_application #[fg=#eba0ac]๎‚ถ#[fg=#11111b,bg=#eba0ac]๏†ฎ #[fg=#cdd6f4,bg=#313244]#{E:@catppuccin_application_text}#[fg=#313244] diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/battery_module.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/battery_module.sh new file mode 100644 index 0000000..9243959 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/battery_module.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash + +script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) +# shellcheck disable=SC1091 +source "${script_dir}/helpers.sh" + +# Tests that the default options are set correctly +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option @catppuccin_status_battery diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/battery_module_expected.txt b/home/config/tmux/plugins/catppuccin/tmux/tests/battery_module_expected.txt new file mode 100644 index 0000000..c29e485 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/battery_module_expected.txt @@ -0,0 +1 @@ +@catppuccin_status_battery #[fg=#b4befe]๎‚ถ#[fg=#11111b,bg=#b4befe]#{l:#{battery_icon}} #[fg=#cdd6f4,bg=#313244]#{E:@catppuccin_battery_text}#[fg=#313244] diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/cpu_module.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/cpu_module.sh new file mode 100644 index 0000000..f6d30cc --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/cpu_module.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash + +script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) +# shellcheck disable=SC1091 +source "${script_dir}/helpers.sh" + +# Tests that the default options are set correctly +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option E:@catppuccin_status_cpu diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/cpu_module_expected.txt b/home/config/tmux/plugins/catppuccin/tmux/tests/cpu_module_expected.txt new file mode 100644 index 0000000..61695f5 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/cpu_module_expected.txt @@ -0,0 +1 @@ +E:@catppuccin_status_cpu #[fg=#f9e2af]๎‚ถ#[fg=#11111b,bg=#f9e2af]๏‹› #[fg=#{cpu_fg_color},bg=#{cpu_bg_color}] #{cpu_percentage}#[fg=#{cpu_bg_color}] diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/default_options.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/default_options.sh new file mode 100755 index 0000000..9d94c0e --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/default_options.sh @@ -0,0 +1,13 @@ +#!/usr/bin/env bash + +script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) +# shellcheck disable=SC1091 +source "${script_dir}/helpers.sh" + +# Tests that the default options are set correctly +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option @catppuccin_flavor +print_option @catppuccin_menu_selected_style +print_option @catppuccin_pane_active_border_style diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/default_options_expected.txt b/home/config/tmux/plugins/catppuccin/tmux/tests/default_options_expected.txt new file mode 100644 index 0000000..4544de4 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/default_options_expected.txt @@ -0,0 +1,3 @@ +@catppuccin_flavor mocha +@catppuccin_menu_selected_style fg=#{@thm_fg},bold,bg=#{@thm_overlay_0} +@catppuccin_pane_active_border_style ##{?pane_in_mode,fg=#{@thm_lavender},##{?pane_synchronized,fg=#{@thm_mauve},fg=#{@thm_lavender}}} diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/harness.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/harness.sh new file mode 100755 index 0000000..ed76b96 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/harness.sh @@ -0,0 +1,153 @@ +#!/usr/bin/env bash + +set -Euo pipefail +trap cleanup SIGINT SIGTERM ERR EXIT + +usage() { + trap - EXIT + cat <&2 -e "${1-}" +} + +msg_verbose() { + if [ "$VERBOSE" = true ]; then + msg "$@" + fi +} + +SOCKET_NAME="${SOCKET_NAME:-test}" +SESSION_NAME="test-session" + +tmux() { + command tmux -L "$SOCKET_NAME" -f /dev/null "$@" +} + +start_tmux_server() { + msg_verbose "${CYAN}Starting tmux server on socket ${SOCKET_NAME}${NOFORMAT}" + tmux new -s "$SESSION_NAME" -d "$(which bash)" +} + +kill_tmux_server() { + msg_verbose "${CYAN}Stopping tmux server${NOFORMAT}" + tmux kill-session "$SESSION_NAME" 2>/dev/null + tmux kill-server 2>/dev/null +} + +cleanup() { + trap - SIGINT SIGTERM ERR EXIT + + # If the session is still running then stop it. + tmux has-session -t "$SESSION_NAME" 2>/dev/null + if test $? -eq 0; then + kill_tmux_server + fi +} + +die() { + local msg=$1 + local code=${2-1} # default exit status 1 + msg "$msg" + + cleanup + + exit "$code" +} + +parse_params() { + # default values of variables set from params + test_script='' + expected_output='' + + while :; do + case "${1-}" in + -h | --help) usage ;; + --no-color) NO_COLOR=1 ;; + -t | --test) + test_script="${2-}" + shift + ;; + -e | --expected) + expected_output="${2-}" + shift + ;; + -v | --verbose) + VERBOSE=true + shift + ;; + -?*) die "Unknown option: $1" ;; + *) break ;; + esac + shift + done + + # shellcheck disable=SC2034 + args=("$@") + + # check required params and arguments + [[ -z "${test_script-}" ]] && die "Missing required parameter: -t|--test" + [[ -z "${expected_output-}" ]] && die "Missing required parameter: -e|--expected" + + return 0 +} + +parse_params "$@" +setup_colors + +run_test() { + msg_verbose "Running test ${test_script} and checking the output against ${expected_output}" + + start_tmux_server + + local script_name + script_name=$(basename "${test_script}") + + local output + # shellcheck disable=SC1090 + output=$(source "${test_script}") + test_exit_code="$?" + + if test $test_exit_code -ne 0; then + die "\n${RED}Test ${script_name} exited with code $test_exit_code ${NOFORMAT}" + fi + + echo -e "${output}" | diff -abB --color=${DIFFCOLORS} "${expected_output}" - + + if test $? -eq 0; then + msg "${GREEN}Test ${script_name} passed${NOFORMAT}" + else + die "\n${RED}Test ${script_name} failed${NOFORMAT}" + fi + + cleanup +} + +run_test diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/helpers.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/helpers.sh new file mode 100644 index 0000000..38ae83c --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/helpers.sh @@ -0,0 +1,30 @@ +#!/usr/bin/env bash + +# Returns the value of given tmux option. +# First argument is the option name, e.g. @catppuccin_flavor. +# +# Usage: `get_option @catppuccin_flavor` +# Would return: `mocha` +# +# The option is given as a format string. +get_option() { + local option + option=$1 + + tmux display-message -p "#{${option}}" +} + +# Prints the given tmux option to stdout. +# First argument is the option name, e.g. @catppuccin_flavor. +# +# Usage: `print_option @catppuccin_flavor` +# Would print: `@catppuccin_flavor mocha` +# +# The option is given as a format string. +print_option() { + local option + option=$1 + + printf "\n%s " "${option}" + get_option "$option" +} diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/load_module.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/load_module.sh new file mode 100644 index 0000000..a1d876c --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/load_module.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash + +script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) +# shellcheck disable=SC1091 +source "${script_dir}/helpers.sh" + +# Tests that the default options are set correctly +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option E:@catppuccin_status_load diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/load_module_expected.txt b/home/config/tmux/plugins/catppuccin/tmux/tests/load_module_expected.txt new file mode 100644 index 0000000..e984dc2 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/load_module_expected.txt @@ -0,0 +1,3 @@ + +E:@catppuccin_status_load #[fg=#89b4fa]๎‚ถ#[fg=#11111b,bg=#89b4fa]๓ฐŠš #[fg=#cdd6f4,bg=#313244]#(uptime | awk '{split(substr($0, index($0, "load")), a, ":"); print a[2]}')#[fg=#313244] + diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/pane_styling.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/pane_styling.sh new file mode 100644 index 0000000..4f5e015 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/pane_styling.sh @@ -0,0 +1,31 @@ +#!/usr/bin/env bash + +script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) +# shellcheck disable=SC1091 +source "${script_dir}/helpers.sh" + +tmux set -g @catppuccin_pane_status_enabled "yes" + +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option pane-border-format + +# Switch the number position to the right +tmux set -g @catppuccin_pane_number_position "right" +tmux source "${script_dir}/../catppuccin_tmux.conf" +print_option pane-border-format + +tmux set -g @catppuccin_pane_number_position "left" # reset + +# Fill option "all" +tmux set -g @catppuccin_pane_default_fill "all" +tmux source "${script_dir}/../catppuccin_tmux.conf" +print_option pane-border-format + +tmux set -g @catppuccin_pane_default_fill "number" # reset + +# Fill option "none" +tmux set -g @catppuccin_pane_default_fill "none" +tmux source "${script_dir}/../catppuccin_tmux.conf" +print_option pane-border-format diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/pane_styling_expected.txt b/home/config/tmux/plugins/catppuccin/tmux/tests/pane_styling_expected.txt new file mode 100644 index 0000000..d57e36f --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/pane_styling_expected.txt @@ -0,0 +1,4 @@ +pane-border-format #[fg=#a6e3a1,bg=default]โ–ˆ#[fg=#313244,bg=#a6e3a1]#{pane_index}#[fg=#a6e3a1,bg=#313244]โ–ˆ #[fg=#a6e3a1,bg=#313244]#{b:pane_current_path}#[fg=#313244,bg=default]โ–ˆ +pane-border-format #[fg=#313244,bg=default]โ–ˆ#[fg=#a6e3a1,bg=#313244]#{b:pane_current_path} #[fg=#a6e3a1,bg=#313244]โ–ˆ#[fg=#313244,bg=#a6e3a1]#{pane_index}#[fg=#a6e3a1,bg=default]โ–ˆ +pane-border-format #[fg=#a6e3a1,bg=default]โ–ˆ#[fg=#313244,bg=#a6e3a1]#{pane_index}#[fg=#a6e3a1,bg=#313244]โ–ˆ #[fg=#313244,bg=#a6e3a1]#{b:pane_current_path}#[fg=#a6e3a1,bg=default]โ–ˆ +pane-border-format #[fg=#313244,bg=default]โ–ˆ#[fg=#cdd6f4,bg=#313244]#{pane_index}#[fg=#cdd6f4,bg=#313244]โ–ˆ #[fg=#cdd6f4,bg=#313244]#{b:pane_current_path}#[fg=#313244,bg=default]โ–ˆ diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/ram_module.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/ram_module.sh new file mode 100644 index 0000000..de53128 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/ram_module.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash + +script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) +# shellcheck disable=SC1091 +source "${script_dir}/helpers.sh" + +# Tests that the default options are set correctly +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option E:@catppuccin_status_ram diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/ram_module_expected.txt b/home/config/tmux/plugins/catppuccin/tmux/tests/ram_module_expected.txt new file mode 100644 index 0000000..e28b5aa --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/ram_module_expected.txt @@ -0,0 +1 @@ +E:@catppuccin_status_ram #[fg=#f9e2af]๎‚ถ#[fg=#11111b,bg=#f9e2af]๎ฟ… #[fg=#{ram_fg_color},bg=#{ram_bg_color}] #{ram_percentage}#[fg=#{ram_bg_color}] diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/window_status_styling.sh b/home/config/tmux/plugins/catppuccin/tmux/tests/window_status_styling.sh new file mode 100644 index 0000000..069a012 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/window_status_styling.sh @@ -0,0 +1,38 @@ +#!/usr/bin/env bash + +# Unsets (removes) any styling options that will contaminate +# subsequent test runs. +function reset() { + tmux set -gu @catppuccin_window_current_left_separator + tmux set -gu @catppuccin_window_current_middle_separator + tmux set -gu @catppuccin_window_current_right_separator + tmux set -gu @catppuccin_window_status_style +} + +script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) +# shellcheck disable=SC1091 +source "${script_dir}/helpers.sh" + +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option window-status-format +print_option window-status-current-format + +# Test the rounded style +reset +tmux set -g @catppuccin_window_status_style "rounded" +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option window-status-format +print_option window-status-current-format + +# Test the basic style with the number on the right +reset +tmux set -g @catppuccin_window_number_position "right" +tmux source "${script_dir}/../catppuccin_options_tmux.conf" +tmux source "${script_dir}/../catppuccin_tmux.conf" + +print_option window-status-format +print_option window-status-current-format diff --git a/home/config/tmux/plugins/catppuccin/tmux/tests/window_status_styling_expected.txt b/home/config/tmux/plugins/catppuccin/tmux/tests/window_status_styling_expected.txt new file mode 100644 index 0000000..2bc69b8 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tests/window_status_styling_expected.txt @@ -0,0 +1,6 @@ +window-status-format #[fg=#11111b,bg=#{@thm_overlay_2}] #I #[fg=#cdd6f4,bg=#{@thm_surface_0}] #T +window-status-current-format #[fg=#11111b,bg=#{@thm_mauve}] #I #[fg=#cdd6f4,bg=#{@thm_surface_1}] #T +window-status-format #[fg=#11111b,bg=#{@thm_overlay_2}]#[fg=#181825,reverse]๎‚ถ#[none]#I #[fg=#cdd6f4,bg=#{@thm_surface_0}] #T#[fg=#181825,reverse]๎‚ด#[none] +window-status-current-format #[fg=#11111b,bg=#{@thm_mauve}]#[fg=#181825,reverse]๎‚ถ#[none]#I #[fg=#cdd6f4,bg=#{@thm_surface_1}] #T#[fg=#181825,reverse]๎‚ด#[none] +window-status-format #[fg=#cdd6f4,bg=#{@thm_surface_0}] #[fg=#cdd6f4,bg=#{@thm_surface_0}] #T #[fg=#11111b,bg=#{@thm_overlay_2}] #I +window-status-current-format #[fg=#cdd6f4,bg=#{@thm_surface_1}] #[fg=#cdd6f4,bg=#{@thm_surface_1}] #T #[fg=#11111b,bg=#{@thm_mauve}] #I diff --git a/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_frappe_tmux.conf b/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_frappe_tmux.conf new file mode 100644 index 0000000..9aeb159 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_frappe_tmux.conf @@ -0,0 +1,34 @@ +# vim:set ft=tmux: + +# --> Catppuccin (Frappe) +set -ogq @thm_bg "#303446" +set -ogq @thm_fg "#c6d0f5" + +# Colors +set -ogq @thm_rosewater "#f2d5cf" +set -ogq @thm_flamingo "#eebebe" +set -ogq @thm_pink "#f4b8e4" +set -ogq @thm_mauve "#ca9ee6" +set -ogq @thm_red "#e78284" +set -ogq @thm_maroon "#ea999c" +set -ogq @thm_peach "#ef9f76" +set -ogq @thm_yellow "#e5c890" +set -ogq @thm_green "#a6d189" +set -ogq @thm_teal "#81c8be" +set -ogq @thm_sky "#99d1db" +set -ogq @thm_sapphire "#85c1dc" +set -ogq @thm_blue "#8caaee" +set -ogq @thm_lavender "#babbf1" + +# Surfaces and overlays +set -ogq @thm_subtext_1 "#a5adce" +set -ogq @thm_subtext_0 "#b5bfe2" +set -ogq @thm_overlay_2 "#949cbb" +set -ogq @thm_overlay_1 "#838ba7" +set -ogq @thm_overlay_0 "#737994" +set -ogq @thm_surface_2 "#626880" +set -ogq @thm_surface_1 "#51576d" +set -ogq @thm_surface_0 "#414559" +set -ogq @thm_mantle "#292c3c" +set -ogq @thm_crust "#232634" + diff --git a/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_latte_tmux.conf b/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_latte_tmux.conf new file mode 100644 index 0000000..0ec65c3 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_latte_tmux.conf @@ -0,0 +1,34 @@ +# vim:set ft=tmux: + +# --> Catppuccin (Latte) +set -ogq @thm_bg "#eff1f5" +set -ogq @thm_fg "#4c4f69" + +# Colors +set -ogq @thm_rosewater "#dc8a78" +set -ogq @thm_flamingo "#dd7878" +set -ogq @thm_pink "#ea76cb" +set -ogq @thm_mauve "#8839ef" +set -ogq @thm_red "#d20f39" +set -ogq @thm_maroon "#e64553" +set -ogq @thm_peach "#fe640b" +set -ogq @thm_yellow "#df8e1d" +set -ogq @thm_green "#40a02b" +set -ogq @thm_teal "#179299" +set -ogq @thm_sky "#04a5e5" +set -ogq @thm_sapphire "#209fb5" +set -ogq @thm_blue "#1e66f5" +set -ogq @thm_lavender "#7287fd" + +# Surfaces and overlays +set -ogq @thm_subtext_1 "#6c6f85" +set -ogq @thm_subtext_0 "#5c5f77" +set -ogq @thm_overlay_2 "#7c7f93" +set -ogq @thm_overlay_1 "#8c8fa1" +set -ogq @thm_overlay_0 "#9ca0b0" +set -ogq @thm_surface_2 "#acb0be" +set -ogq @thm_surface_1 "#bcc0cc" +set -ogq @thm_surface_0 "#ccd0da" +set -ogq @thm_mantle "#e6e9ef" +set -ogq @thm_crust "#dce0e8" + diff --git a/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_macchiato_tmux.conf b/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_macchiato_tmux.conf new file mode 100644 index 0000000..b1a43c2 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_macchiato_tmux.conf @@ -0,0 +1,34 @@ +# vim:set ft=tmux: + +# --> Catppuccin (Macchiato) +set -ogq @thm_bg "#24273a" +set -ogq @thm_fg "#cad3f5" + +# Colors +set -ogq @thm_rosewater "#f4dbd6" +set -ogq @thm_flamingo "#f0c6c6" +set -ogq @thm_pink "#f5bde6" +set -ogq @thm_mauve "#c6a0f6" +set -ogq @thm_red "#ed8796" +set -ogq @thm_maroon "#ee99a0" +set -ogq @thm_peach "#f5a97f" +set -ogq @thm_yellow "#eed49f" +set -ogq @thm_green "#a6da95" +set -ogq @thm_teal "#8bd5ca" +set -ogq @thm_sky "#91d7e3" +set -ogq @thm_sapphire "#7dc4e4" +set -ogq @thm_blue "#8aadf4" +set -ogq @thm_lavender "#b7bdf8" + +# Surfaces and overlays +set -ogq @thm_subtext_1 "#a5adcb" +set -ogq @thm_subtext_0 "#b8c0e0" +set -ogq @thm_overlay_2 "#939ab7" +set -ogq @thm_overlay_1 "#8087a2" +set -ogq @thm_overlay_0 "#6e738d" +set -ogq @thm_surface_2 "#5b6078" +set -ogq @thm_surface_1 "#494d64" +set -ogq @thm_surface_0 "#363a4f" +set -ogq @thm_mantle "#1e2030" +set -ogq @thm_crust "#181926" + diff --git a/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_mocha_tmux.conf b/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_mocha_tmux.conf new file mode 100644 index 0000000..994553c --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/themes/catppuccin_mocha_tmux.conf @@ -0,0 +1,34 @@ +# vim:set ft=tmux: + +# --> Catppuccin (Mocha) +set -ogq @thm_bg "#1e1e2e" +set -ogq @thm_fg "#cdd6f4" + +# Colors +set -ogq @thm_rosewater "#f5e0dc" +set -ogq @thm_flamingo "#f2cdcd" +set -ogq @thm_pink "#f5c2e7" +set -ogq @thm_mauve "#cba6f7" +set -ogq @thm_red "#f38ba8" +set -ogq @thm_maroon "#eba0ac" +set -ogq @thm_peach "#fab387" +set -ogq @thm_yellow "#f9e2af" +set -ogq @thm_green "#a6e3a1" +set -ogq @thm_teal "#94e2d5" +set -ogq @thm_sky "#89dceb" +set -ogq @thm_sapphire "#74c7ec" +set -ogq @thm_blue "#89b4fa" +set -ogq @thm_lavender "#b4befe" + +# Surfaces and overlays +set -ogq @thm_subtext_1 "#a6adc8" +set -ogq @thm_subtext_0 "#bac2de" +set -ogq @thm_overlay_2 "#9399b2" +set -ogq @thm_overlay_1 "#7f849c" +set -ogq @thm_overlay_0 "#6c7086" +set -ogq @thm_surface_2 "#585b70" +set -ogq @thm_surface_1 "#45475a" +set -ogq @thm_surface_0 "#313244" +set -ogq @thm_mantle "#181825" +set -ogq @thm_crust "#11111b" + diff --git a/home/config/tmux/plugins/catppuccin/tmux/tmux.tera b/home/config/tmux/plugins/catppuccin/tmux/tmux.tera new file mode 100644 index 0000000..93330ac --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/tmux.tera @@ -0,0 +1,42 @@ +--- +whiskers: + version: "^2.5.1" + matrix: + - flavor + filename: "themes/catppuccin_{{flavor.identifier}}_tmux.conf" + hex_format: "#{{r}}{{g}}{{b}}{{z}}" +--- +# vim:set ft=tmux: + +# --> Catppuccin ({{ flavor.identifier | capitalize }}) +set -ogq @thm_bg "{{ base.hex }}" +set -ogq @thm_fg "{{ text.hex }}" + +# Colors +set -ogq @thm_rosewater "{{ rosewater.hex }}" +set -ogq @thm_flamingo "{{ flamingo.hex }}" +set -ogq @thm_pink "{{ pink.hex }}" +set -ogq @thm_mauve "{{ mauve.hex }}" +set -ogq @thm_red "{{ red.hex }}" +set -ogq @thm_maroon "{{ maroon.hex }}" +set -ogq @thm_peach "{{ peach.hex }}" +set -ogq @thm_yellow "{{ yellow.hex }}" +set -ogq @thm_green "{{ green.hex }}" +set -ogq @thm_teal "{{ teal.hex }}" +set -ogq @thm_sky "{{ sky.hex }}" +set -ogq @thm_sapphire "{{ sapphire.hex }}" +set -ogq @thm_blue "{{ blue.hex }}" +set -ogq @thm_lavender "{{ lavender.hex }}" + +# Surfaces and overlays +set -ogq @thm_subtext_1 "{{ subtext0.hex }}" +set -ogq @thm_subtext_0 "{{ subtext1.hex }}" +set -ogq @thm_overlay_2 "{{ overlay2.hex }}" +set -ogq @thm_overlay_1 "{{ overlay1.hex }}" +set -ogq @thm_overlay_0 "{{ overlay0.hex }}" +set -ogq @thm_surface_2 "{{ surface2.hex }}" +set -ogq @thm_surface_1 "{{ surface1.hex }}" +set -ogq @thm_surface_0 "{{ surface0.hex }}" +set -ogq @thm_mantle "{{ mantle.hex }}" +set -ogq @thm_crust "{{ crust.hex }}" + diff --git a/home/config/tmux/plugins/catppuccin/tmux/utils/status_module.conf b/home/config/tmux/plugins/catppuccin/tmux/utils/status_module.conf new file mode 100644 index 0000000..fc72578 --- /dev/null +++ b/home/config/tmux/plugins/catppuccin/tmux/utils/status_module.conf @@ -0,0 +1,47 @@ +# vim:set ft=tmux: + +# Embedded style that ensures that modules look "connected" +# when required. +set -gqF @_ctp_connect_style \ + "#{?#{==:#{@catppuccin_status_connect_separator},yes},,#[bg=default]}" + +# There are four colors involved: +# +# - Icon +# - fg: @catppuccin_status_[module]_icon_fg [default = crust] +# - bg: @catppuccin_status_[module]_icon_bg [required] +# - Text +# - fg: @catppuccin_status_[module]_text_fg [default = foreground] +# - bg: @catppuccin_status_[module]_text_bg [default = @catppuccin_status_module_text_bg] + +set -ogqF "@catppuccin_status_${MODULE_NAME}_icon_fg" "#{E:@thm_crust}" +set -ogqF "@catppuccin_status_${MODULE_NAME}_text_fg" "#{E:@thm_fg}" + +%if "#{==:#{@catppuccin_status_${MODULE_NAME}_icon_bg},}" + set -gqF "@catppuccin_status_${MODULE_NAME}_icon_bg" "#{@catppuccin_${MODULE_NAME}_color}" +%endif + +%if "#{==:#{@catppuccin_status_${MODULE_NAME}_text_bg},}" + set -gqF @_ctp_module_text_bg "#{E:@catppuccin_status_module_text_bg}" +%else + set -gqF @_ctp_module_text_bg "#{@catppuccin_status_${MODULE_NAME}_text_bg}" +%endif + +set -gF "@catppuccin_status_${MODULE_NAME}" \ + "#[fg=#{@catppuccin_status_${MODULE_NAME}_icon_bg}]#{@_ctp_connect_style}#{@catppuccin_status_left_separator}" + +set -agF "@catppuccin_status_${MODULE_NAME}" \ + "#[fg=#{@catppuccin_status_${MODULE_NAME}_icon_fg},bg=#{@catppuccin_status_${MODULE_NAME}_icon_bg}]#{@catppuccin_${MODULE_NAME}_icon}" + +set -agF "@catppuccin_status_${MODULE_NAME}" \ + "#{@catppuccin_status_middle_separator}" + +set -agF "@catppuccin_status_${MODULE_NAME}" \ + "#[fg=#{@catppuccin_status_${MODULE_NAME}_text_fg},bg=#{@_ctp_module_text_bg}]" + +set -ag "@catppuccin_status_${MODULE_NAME}" "#{E:@catppuccin_${MODULE_NAME}_text}" + +set -agF "@catppuccin_status_${MODULE_NAME}" "#[fg=#{@_ctp_module_text_bg}]#{@_ctp_connect_style}#{@catppuccin_status_right_separator}" + +set -ug @_ctp_connect_style +set -ug @_ctp_module_text_bg diff --git a/home/config/tmux/tmux.conf b/home/config/tmux/tmux.conf new file mode 100644 index 0000000..cf4bfca --- /dev/null +++ b/home/config/tmux/tmux.conf @@ -0,0 +1,28 @@ +set-option -sa terminal-overrides ",xterm*:Tc" + +bind '"' split-window -v -c "#{pane_current_path}" +bind % split-window -h -c "#{pane_current_path}" + +set -g mouse on +set -g base-index 1 +set -g pane-base-index 1 +set-window-option -g pane-base-index 1 +set-option -g renumber-windows on + +set -g @plugin 'tmux-plugins/tpm' + +run ~/.config/tmux/plugins/catppuccin/tmux/catppuccin.tmux +set -g @catppuccin_flavor 'mocha' # latte, frappe, macchiato or mocha + +set -g @plugin 'tmux-plugins/tmux-yank' + +set -g @plugin 'tmux-plugins/tmux-sensible' + +# Other examples: +# set -g @plugin 'github_username/plugin_name' +# set -g @plugin 'github_username/plugin_name#branch' +# set -g @plugin 'git@github.com:user/plugin' +# set -g @plugin 'git@bitbucket.com:user/plugin' + +# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf) +run '~/.tmux/plugins/tpm/tpm' diff --git a/home/default.nix b/home/default.nix index a9136cb..944efae 100644 --- a/home/default.nix +++ b/home/default.nix @@ -8,6 +8,7 @@ home.file = { ".config/hypr".source = ./config/hypr; + ".config/tmux".source = ./config/tmux; }; home.username = "river";