Can a VIPM package repository be set up on GitHub?

Viewed 283

VIPM stands for Virtual Instrument Package Manager. It is a manager of install-able packages for NI LabVIEW. It is published by JKI Software and a free version of it is distributed with LabVIEW.

Registered (paying) users can set up public or private VI Package repositories. I would like to set one up on GitHub.

I attempted to do so by first creating a VI Repository on my local hard drive, publishing some packages to it, then making a remote clone on GitHub. Using the VIPM Repository Manager, I added the repository by browsing to the index.vipr file on my remote GitHub clone. However, VIPM gives me an error saying that the repository was not found.

Has anyone managed to set up and subscribe VI package repository on GitHub?

1 Answers

The short answer is that GitHub and a VIPM repository are fundamentally different and unless VIPM adds support for git repositories and GitHub then I doubt it will be possible.

If you are considering managing dependencies of any project using GitHub as a source for your shared libraries then you might want to consider a package manager like yarn.

Yarn (and others like npm and bower) are capable of fetching (cloning) from GitHub and follow the common practice from the Web developer world (and others) of having all a project's dependencies contained within the project; This is a departure from the VIPM view where you update your development environment (LabVIEW) by installing the packages 'globally'.

A list of the project's installed libraries and the library versions are stored in a human-readable file called package.json which provides a portable way of getting the project setup on another machine.

As new releases of the libraries happen, you can choose when to update the library in your project by selectively updating the libraries.

This approach works well with LabVIEW packed libraries (.lvlibp) as opposed to VIPM packages as there is no install-into-LabVIEW-IDE step with packed-libraries. If you have a hierarchy of packed libraries then they can also specify their dependent libraries using a package.json and then yarn can install all the libraries recursively.

It is possible to configure Yarn to place libraries into a folder of your own choosing instead of the default node_modules (as used by Node.js).

The advantages of this are:

  • You can choose which versions of libraries to use per project
  • Package managers integrate nicely with automatic testing and building setups
  • You can use GitHub or other git-providers for publishing your libraries

The disadvantages are:

  • More setup
  • It is not a common approach in the LabVIEW development world
  • Your VIs won't be installed into the LabVIEW palettes unless you explicitly install them
Related