Pijul

New repo folders are...files on Nest?

I’ve been looking for an excuse to use Pijul for a while now and seem to have found it, but I ran into a slight oddity. Here’s the gist of it:

  • The repository on Nest shows syntaxes as if it were a file.
  • pijul ls locally shows it being a directory with a jsonnet file inside:
    $ pijul ls                                                 
    CHANGELOG.md
    README.md
    language-configuration.json
    package.json
    syntaxes
    syntaxes/s3air-lemon.tmLanguage.jsonnet
    

So I’m not sure what exactly is wrong here…

Hi! Welcome here! You’re not doing anything wrong, there’s a bug in the Nest. Thanks for finding it, I’ll fix it ASAP.

It seems your initial change was recorded by a bad version of Pijul, it’s fixed in the version on the Nest. I’ll publish a fix on crates.io today.

Something just occurred to me: are you on Windows?

Nope, this is on a Debian container inside Chrome OS.

Do I need to update my local version and/or re-push or similar, or is this solely dependent on the version Nest runs?

If you’re hitting the same issue I’ve been hitting, I think this needs a new version on your end. To check, add a folder to a repo locally, then try running pijul record twice. The second one shouldn’t do anything, but for me, on alpha 48, it does.

This also happened in a very early version of pijul. I thought, this was a feature, so you don’t have to put empty hidden files into a directory, which is meant to be empty, like in git.

What we ran into isn’t that “directories are tracked independently of their contents”, it’s that “the initial record of a directory, regardless of whether it contains anything, is a file, which leads to an immediate dirty repo state requiring a second record to convert the file to a directory”.