Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/alexherbo2/kakoune.cr
A command-line tool for Kakoune
https://github.com/alexherbo2/kakoune.cr
cli crystal kakoune plugin
Last synced: about 1 month ago
JSON representation
A command-line tool for Kakoune
- Host: GitHub
- URL: https://github.com/alexherbo2/kakoune.cr
- Owner: alexherbo2
- License: unlicense
- Created: 2021-02-07T16:49:09.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-05-02T14:40:52.000Z (over 2 years ago)
- Last Synced: 2024-05-21T04:25:00.775Z (4 months ago)
- Topics: cli, crystal, kakoune, plugin
- Language: Crystal
- Homepage: https://kakoune.org
- Size: 174 KB
- Stars: 51
- Watchers: 1
- Forks: 11
- Open Issues: 11
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING
- Funding: .github/FUNDING.yml
Awesome Lists containing this project
README
# kakoune.cr
###### [Installation] | [Guide] | [Manual]
[Installation]: #installation
[Guide]: docs/guide.md
[Manual]: docs/manual.mdkakoune.cr (kcr) is a command-line tool for [Kakoune].
It is a great companion to work with projects, multiple files and headless sessions.
[Kakoune]: https://kakoune.org
[![Thumbnail](https://img.youtube.com/vi_webp/FUndUED1O7Q/maxresdefault.webp)](https://youtube.com/playlist?list=PLdr-HcjEDx_klQYqXIAmBpywj7ggsDPer)
[![Button](https://www.iconfinder.com/icons/317714/download/png/16)](https://youtube.com/playlist?list=PLdr-HcjEDx_klQYqXIAmBpywj7ggsDPer)###### What can I do?
- Connect applications to Kakoune.
- Control Kakoune from the command-line.
- Manage sessions.
- Write plugins.Give it a spin: [`kcr tldr`] & [`kcr play`].
[`kcr tldr`]: docs/manual.md#tldr
[`kcr play`]: docs/manual.md#playSee what’s new with [`kcr -V`] | [`kcr --version-notes`] or read the [changelog].
[`kcr -V`]: docs/manual.md#options
[`kcr --version-notes`]: docs/manual.md#options[Changelog]: CHANGELOG.md
###### How does it work?
kakoune.cr is based around the concept of contexts, which can be set via the [`--session`] and [`--client`] options.
[`--session`]: docs/manual.md#options
[`--client`]: docs/manual.md#optionsFor example, the following command will open the file in the **main** client of the **kanto** session.
``` sh
kcr edit --session=kanto --client=main pokemon.json
```Most of the time, you don’t need to specify them.
[`connect`] will forward [`KAKOUNE_SESSION`] and [`KAKOUNE_CLIENT`] environment variables,
which will be used by [`kcr`] to run commands in the specified context.[`kcr`]: docs/manual.md
[`connect`]: docs/manual.md#connect
[`KAKOUNE_SESSION`]: docs/manual.md#environment-variables
[`KAKOUNE_CLIENT`]: docs/manual.md#environment-variables**Example** – Connect a terminal:
``` kak
connect terminal
```**Example** – Connect a program:
``` kak
connect run alacritty
```## Dependencies
- [Crystal]
- [Shards]
- [jq][Crystal]: https://crystal-lang.org
[Shards]: https://github.com/crystal-lang/shards
[jq]: https://stedolan.github.io/jq/## Installation
### Nightly builds
Download the [Nightly builds].
[Nightly builds]: https://github.com/alexherbo2/kakoune.cr/releases/nightly
### Build from source
Run the following in your terminal:
``` sh
make install
```### Kakoune definitions
Add the [Kakoune definitions] to your **kakrc**.
``` kak
evaluate-commands %sh{
kcr init kakoune
}
```[Kakoune definitions]: docs/manual.md#init-kakoune