Skip to content

Conversation

@bkirwi
Copy link

@bkirwi bkirwi commented Jan 29, 2022

👋 This is a new package for the interactive fiction interpreter I've been working on, https://github.com/bkirwi/folly

I've developed it entirely on RM2, though @Eeems was kind enough to test on RM1 a while back. I've checked that the package installs on my tablet, and I've spent quite a lot of time running the software itself, but let me know if there's more specific testing I should take on.

Note that this autocreates the ~/folly/ directory, and adds a few files to it, if it doesn't already exist. Happy to configure or change that if that path seems inappropriate.

I've also made a small quality-of-life change to builder.py, printing the hashes that don't match, since that makes spotting errors or updating the file somewhat easier. (And gitignoring .venv, since that's not checked in.)

@raisjn
Copy link
Contributor

raisjn commented Jan 30, 2022

looks awesome, can't wait to try it out! i think setting the FOLLY_ROOT to somewhere in /opt/ makes sense

Copy link
Contributor

@raisjn raisjn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

back on your plate for rM1 compatibility

Copy link
Member

@LinusCDE LinusCDE left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On the rM 1, the pen keeps drawing when not touching anymore. So not really working on that model.

This may be what was found on discord already and will probably get fixed by canselcik/libremarkable#97 .

@bkirwi
Copy link
Author

bkirwi commented Feb 9, 2022

Yeah, apologies, should have updated this PR when that was found! Agree that the PR you linked is intended to fix... I should get an update in this PR within a day or so.

Copy link
Member

@LinusCDE LinusCDE left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Package works well on the rM 1 now! Nice tutorial!

  • Please remove the majority of comments from the package file.

Next time it would also be nice to have the .env and builder.py changes be a separate PR. But I don't mind it this time.

LinusCDE
LinusCDE previously approved these changes Feb 10, 2022
Copy link
Member

@LinusCDE LinusCDE left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! Merging..

@LinusCDE LinusCDE requested a review from raisjn February 10, 2022 16:15
@LinusCDE
Copy link
Member

LinusCDE commented Feb 10, 2022

Ah. Seems that raisjn's review is still outstanding.

i think setting the FOLLY_ROOT to somewhere in /opt/ makes sense

@raisjn, are you considering it okay to merge despite default stories being installed to /home/root/folley? I don't really have a strong opinion regarding this. Your call.

@bkirwi
Copy link
Author

bkirwi commented Feb 10, 2022

Package works well on the rM 1 now! Nice tutorial!

Thanks, and glad to hear it!

Please remove the majority of comments from the package file.

Done!

Next time it would also be nice to have the .env and builder.py changes be a separate PR. But I don't mind it this time.

Noted!

@bkirwi
Copy link
Author

bkirwi commented Feb 10, 2022

Ah. Seems that raisjn's review is still outstanding.

Ah yes, right, sorry I missed it! I do feel a bit weird about using /opt for user data, including saves and things. Another alternative I was considering was to use $HOME/.local/share like xochitl does. But I notice plato uses a top-level directory in home, so it looks like there may not be a standard yet?

@LinusCDE
Copy link
Member

Yeah. There is no real standard yet. I put saves/configs of my games into /home/root/.config/<name>. Of note is that I never have any of these files in my package, so they're either created by the app or an configure script.

As for plato, I preferred this folder to make it easier for users to find. But I only create it in the configure script and don't have the package maintain that folder (or files in it) directly. Since you have default files, I'm not sure whats best to proceed here. Maybe put these files into a default location (like /opt/usr/share/folley) and let the configure script do a symlink to the current location the first time.

Opkg seems to be not that particular about stuff especially if new folders are creates, but having default fails technically be managed by the package manager, might cause some problems if people just delete them later.

@Eeems
Copy link
Member

Eeems commented Feb 10, 2022

Yeah. There is no real standard yet.

Technically the XDG standard does exist, and we just use /opt as the root instead of / for any paths outside of /home in that standard.

@LinusCDE
Copy link
Member

Technically the XDG standard does exist, and we just use /opt as the root instead of / for any paths outside of /home in that standard.

Yeah. But this is usually for configurations. And /home/root is easy to find by users while also preventing data loss, should they completely uninstall toltec and therefore whipe everything in /opt. And some apps use /opt/share/ while others use /opt/usr/share, so not quite 100% mapped to /opt.

@Eeems
Copy link
Member

Eeems commented Feb 10, 2022

Yeah. But this is usually for configurations.

The XDG standard also covers data storage. https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html

If $XDG_DATA_DIRS is either not set or empty, a value equal to /usr/local/share/:/usr/share/ should be used.

The ArchWiki has a good write-up on it: https://wiki.archlinux.org/title/XDG_Base_Directory#User_directories

@LinusCDE
Copy link
Member

For end-user friendly ness (who don't necessarily know to look in some hidden subfolder), having it obvious findable when using a file manager is helpful though. My main concern is whether it is good from a packaging standpoint to have files lying around that a user thinks he should delete and the package manager thinks, it alone should manage them.

@bkirwi
Copy link
Author

bkirwi commented Feb 11, 2022

Technically the XDG standard does exist [...]

For sure -- I just meant that it wasn't consistently followed. But it sounds like that's the way to go here... I'll follow up with that change.

For end-user friendly ness (who don't necessarily know to look in some hidden subfolder), having it obvious findable when using a file manager is helpful though.

Definitely my original motive for the choice! But I appreciate that not everyone wants their home directory cluttered, and I'm optimistic that it won't be too much of an issue in practise.

Thanks everyone for weighing in!

@raisjn
Copy link
Contributor

raisjn commented Feb 12, 2022

can you clarify what directory for saves you went with?

@bkirwi
Copy link
Author

bkirwi commented Feb 12, 2022

can you clarify what directory for saves you went with?

For sure - all user data (including saves and any other files that the app creates) are now stored under ~/.local/share/folly.

Copy link
Contributor

@raisjn raisjn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good

@LinusCDE LinusCDE merged commit be46686 into toltec-dev:testing Feb 12, 2022
raisjn added a commit that referenced this pull request Feb 18, 2022
New Packages:

* Add new rmkit apps: dumbskull, rpncalc and wordlet (#542)
* Add package for Folly (z-machine interpreter) (#543)

Updated Packages:

* Update KOReader to v2022.01 (#517)
* Update innernet to 1.5.3 (#545)
* Update to all rmkit applications (#542)
* Update plato to 0.9.25 (#534)
* Update rm2fb to v0.0.14 (#552)

Misc:

* Remove outdated todo from opkg completion (#541)
raisjn added a commit that referenced this pull request Feb 21, 2022
* Stable merge for week 6 of 2022

New Packages:

* Add new rmkit apps: dumbskull, rpncalc and wordlet (#542)
* Add package for Folly (z-machine interpreter) (#543)

Updated Packages:

* Update KOReader to v2022.01 (#517)
* Update innernet to 1.5.3 (#545)
* Update to all rmkit applications (#542)
* Update plato to 0.9.25 (#534)
* Update rm2fb to v0.0.14 (#552)

Misc:

* Remove outdated todo from opkg completion (#541)

* Add hotfixes from #560

Co-authored-by: raisjn <raisjn@users.noreply.github.com>
Co-authored-by: Mattéo Delabre <git.matteo@delab.re>
matteodelabre added a commit to toltec-dev/build that referenced this pull request Mar 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants