Jrnl notes/journal taking on console for Rocky (NS8)?

Hi,

I would like to explore jrnl a journal/notes taking application for the command line.

Any thoughts on how to easily install it without a huge amount of dependencies, python,extra modules etc?

TIA!

For pipx Python 3.10 is wanted but Rocky has 3.9 so I did it with brew.

You need to create a user with sudo rights to install homebrew:

adduser -g wheel jrnluser

Set a password:

passwd jrnluser

Install git:

dnf install git -y

Login as the created jrnluser

su - jrnluser

Install homebrew:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Set PATH for homebrew:

(echo; echo 'eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"') >> /home/jrnluser/.bashrc

Apply path:

eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"

Install jrnl:

brew install jrnl

Start and use it:

jrnl

Very slick, I am stuck here:

[jrnluser@srv1 ~]$ (echo; echo 'eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"') >> /home/jbrluser/.bashrc
-bash: /home/jbrluser/.bashrc: No such file or directory

Ah, typo

(echo; echo ‘eval “$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)”’) >> /home/jrnluser/.bashrc

1 Like

I corrected it.

1 Like

And now it is going to install a compile environment?

[jrnluser@srv1 home]$ brew install jrnl
==> Auto-updating Homebrew...
Adjust how often this is run with HOMEBREW_AUTO_UPDATE_SECS or disable with
HOMEBREW_NO_AUTO_UPDATE. Hide these hints with HOMEBREW_NO_ENV_HINTS (see `man brew`).
==> Downloading https://ghcr.io/v2/homebrew/core/jrnl/manifests/4.1-1
################################################################################################### 100.0%
==> Fetching dependencies for jrnl: linux-headers@5.15, glibc, gmp, isl, mpfr, libmpc, lz4, xz, zlib, zstd, binutils, gcc, pycparser, libffi, cffi, ca-certificates, openssl@3, cryptography, libyaml, mpdecimal, ncurses, readline, sqlite, berkeley-db@5, libedit, krb5, libtirpc, libnsl, bzip2, expat, libxcrypt, unzip and python@3.12

They say it is a package manager but yes…
I found no other/easier way to install…

Thanks. Is there a way I can uninstall and dependencies please?

ps.

It seems root can not use jrnl.

But thanks anyway!

1 Like

Uninstall homebrew package:

brew uninstall jrnl

Uninstall homebrew:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/uninstall.sh)"
1 Like

Thanks. FYI I am reading about snapd from EPEL that may allow an easy install…

1 Like

This worked for me:

dnf install epel-release --enablerepo=devel
dnf install snapd
systemctl enable --now snapd.socket
ln -s /var/lib/snapd/snap /snap
snap install --edge jrnl

Before executing snap install… wait a bit for the snap etc to have initialised, you may run into an error. Try again after a bit.
To have snap take effect for root, logoff and login again as root (my ugly hack)

Then

jrnl

Use at your own risk. NO idea if snap is to be trusted or any app installed with snap!

FYI

So what is my reason behind this ‘madness’? Back in the day (and soonish NS7 will be gone too) I misused the e-smith db system for making some quick notes. To me it was very handy for I could store data under a key in. a structured way. And config show ‘mykey’ was all I need to show that data.

I know, completely useless to many, but it did not interfere with the db system, and it was an easy mechanism to make important notes such as passwords etc. Als the ‘export’ function (config show → my_export.txt) was very handy for backup purposes.

Now I am trying my luck with jrnl. I am sure there are other tools that are being used, or wiki etc, but that’s a lot of overhead whilst on the console. That’s it, UNLESS somebody ports the ‘db key’ app light version to NS8 for the simple db structure, storage and usage.

HTH

ps. Now it would be interesting to see if jrnl and Dokuwiki (both flat file based) can use the same files… Best of both worlds??

I’ve got that working. I created a symbolic link from:

/home/dokuwiki1/.local/share/containers/storage/volumes/dokuwiki-data/_data/data/pages/jrnl

to

/root/jrnl

“…/pages/jrnl” is a seperate namespace called jrnl in dokuwiki and journal is the pagename (.txt is added autoamtically by Dokuwiki)

Pointed the jrnl config file (jrnl.yml) to the symbolic link and voila.

If I create an entry in jrnl or dokuwiki, it shows up in both. I’m sure a bit of formatting can be done, but it basically works.

HTH

ps. Best order of working is to first create the namespace in Dokuwiki, then create the symbolic link and then start jrnl for the first time or adjust the jrnl.yml config file to point to the symbolic link.

So now, whenever a console user adds and jrnl entry from the console while working (make a quick note), it shwos up in Dokuwiki, is searchable and also non root users can consult the wiki if authorised… And obviously every other dokuwiki operation like print, export to PDF etc etc.

Since the jrnl data is actually a part of Dokuwiki this way, all jrnl entries are automatically backup up with Dokuwiki too (and restored).

1 Like

I hoped so… :slight_smile:

Snap is eating my server resources.