Skip to content

urza/cln

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 

Repository files navigation

core lightning bits

  • These code snippets assume running on ubuntu server native (not docker or umbrell and such).
  • CLN has great documentation

✨ create alias "cln" for "lightning-cli"

  • if lightning-cli is in PATH:

echo "alias cln='lightning-cli'" >> ~/.bash_aliases && source ~/.bash_aliases

  • or absolute path:

echo "alias cln='/path/to/lightning-cli'" >> ~/.bash_aliases && source ~/.bash_aliases

✨ bash auto completion for cln

curl https://raw.githubusercontent.com/urza/cln/main/cln.bash-completion > cln.bash-completion
sudo cp cln.bash-completion /etc/bash_completion.d/cln.bash-completion

restart your terminal session
then test:
cln set[tab tab]
should offer you
setchannel setconfig setleaserates setpsbtversion

Example of completion with FZF

✨ ppm to % table

(understand your fees) cln setchannel short_chan_id base_fee ppm_fee

PPM %
10 ppm 0.001%
100 ppm 0.01%
500 ppm 0.05%
1000 ppm 0.1%
10_000 ppm 1%

✨ amount in sats

Millisatoshis are annoying. Luckily in most places when working with lightning-cli you can provide amount as sats or even btc using "sat" or "btc" suffix.
For example:
cln invoice 50000sat label_test_77 description_test

About

core lightning bits

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages