Yak package description


Thank you for yak, it is really great to have it.

I would like to ask if it is possible to automatically generate the package description after writing:

> "C:\Program Files\Rhino 6\System\Yak.exe" spec

Inspecting content: Plankton.gha

name: marmoset
version: 1.0.0
- <author>
description: <description>
url: <url>
  id: c9beedb9-07ec-4974-a0a2-44670ddb17e4

Saved to C:\Users\Bozo\dist\manifest.yml

In the Visual Studio project file I have this written but nothing goes to description and I have to manually change it:

using System;
using System.Drawing;
using Grasshopper.Kernel;

namespace NGonGh {
    public class SubDInfo : GH_AssemblyInfo {
        public override string Name => "NGon";

        public override string Version => "2.3.0";
        public override string AssemblyName => "Ngon";

        public override string AssemblyVersion => "2.3.0";


        public override string AssemblyDescription => "Polygonal Mesh Processing";
        public override Bitmap Icon => Properties.Resources.Icons_NGons_FromPolylines;

        public override string Description => "Extension methods for easier NGons manipulation in Meshes";

        public override Guid Id => new Guid("20563e24-568f-4f4f-b61b-71a1781ef92f");

        public override string AuthorName => "Petras Vestartas";

        public override string AuthorContact => "www.petrasvestartas.com";

        public override Bitmap AssemblyIcon => Properties.Resources.Icons_NGons_FromPolylines;


And for updates, can I build Visual Studio project push it to the Server and will the previous version will be overwritten?

Also once the user installs the package how he/she can remove it?

There is an uninstall button in the Installed section of the PackageManager.

Hey Petras,

Thanks for pointing out that the description field wasn’t being extracted from GHAs by the spec command. I’ve fixed it and an updated version of yak.exe will be in the next Rhino WIP release.

You can only use a version number once. If you want to publish an update to your package then you need to pick a new version number. For example, if you’ve already published “1.0.0”, then you should pick “1.0.1” or “1.1.0” (or “2.0.0”) for the next release. I recommend reading semver.org.

The reason for not allowing versions to be overwritten (or deleted) is that users may rely on a specific version for their work. If you want to discourage the use of an existing version then you can hide it with the yank command. Hidden (yanked) packages can still be installed if the user knows the exact version number, but they won’t show up in the package manager.

Nathan’s right – I recently added an uninstall button to the Package Manager in Rhino WIP.

I noticed you’re using the Rhino 6 version of the Yak CLI tool. I recommend using the Rhino 7 WIP version for publishing packages since it supports new things like distributions, keywords and managing package ownership, along with a bunch of smaller updates and bug fixes.

Thank you for a reply.

Most of the users still using Rhino 6.
Is there any chance that these updates or at least uninstall button would appear on Rhino 6 as well?

When the number of the package is changed and I press button update, would the last version will be overwritten in my computer i.e. Plugin1.0.0 will become Plugin1.0.1?

Most of these updates are related to authoring packages. You can use the newer version of the Yak CLI tool to publish packages that will be installed and used by users that have Rhino 6. I encourage you to read the updated guide to creating a grasshopper plugin package.

It wouldn’t be trivial to backport the uninstall button to the TestPackageManager in Rhino 6. I’d rather focus on delivering Rhino 7 sooner. The package manager in Rhino 7 is a significant improvement. In Rhino 6, you can uninstall packages using the CLI.

"C:\Program Files\Rhino 6\System\yak.exe" uninstall plankton

The new version is installed alongside the old version. When Rhino is restarted it will use the new version. It’s done this way because it’s often not possible to remove the old files if they’re in use, for example a plug-in currently loaded by Rhino.

Thank you.

I would really like to have that unistall button.
I know that Rhino 7WIP has large improvements, but there is always a very slow transition to newer Rhino version. I remember how it was for 5 and 6, mac and windows, especially it is hard for workshops and students.