pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Pkgsrc WIP package to upgrade Helix to 25.07.1



On Wed, Nov 05, 2025 at 04:16:27PM +0100, atomicules wrote:
> I've added a WIP entry to update Helix editor to
> 25.07.1: https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?
> p=pkgsrc-wip.git;a=commitdiff;h=04aa021d3c65500e8cfdb4885974dbbe4f86bb83
> 
> Could someone please help me finesse that and get it updated in CVS
> main? The bits I'm unsure about:
> 
> 1. How best to handle the codeberg.org dowload; Most tree-sitter
> grammars come from github.org and when extracted include the revision in
> the folder/directory name. From codeberg.org they don't. There is only
> one download from codeberg.org. I'm special-casing this in the Makefile
> at the moment.

As long as it works...

> 2. Whether it's ok to keep the awk parsing of toml - I've had to tweak
> that a bit.

Also, as long as it works - but this has enough dependencies that it
wouldn't matter if you used e.g. python/tool.mk and parse it using
Python.

> 3. What to do about the `SUBST_` entries. Some aren't needed so I've
> just commented out for now.

There is a part of a patch you removed:

@@ -90,14 +88,8 @@ fn prioritize_runtime_dirs() -> Vec<Path
         rt_dirs.push(dir.into());
     }

-    // fallback to location of the executable being run
-    // canonicalize the path in case the executable is symlinked
-    let exe_rt_dir = std::env::current_exe()
-        .ok()
-        .and_then(|path| std::fs::canonicalize(path).ok())
-        .and_then(|path| path.parent().map(|path| path.to_path_buf().join(RT_DIR)))
-        .unwrap();
-    rt_dirs.push(exe_rt_dir);
+    rt_dirs.push(PathBuf::from("@DATADIR@").join(RT_DIR));
+
     rt_dirs
 }


which looks like it hardcoded the pkgsrc path to DATADIR into the
binary ($PREFIX/share/helix), but which is not there any longer.
Restoring that would make the SUBST useful again.

I'm not sure if it's need or not. I started helix on a file and it
worked. I didn't see any syntax highlighting though, so perhaps it was
needed for finding the tree-sitter grammars?
 Thomas


Home | Main Index | Thread Index | Old Index