Change default package directory from octave to .octave, or ask before first package installation

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Change default package directory from octave to .octave, or ask before first package installation

Tasos Papastylianou
The current choice of default installation directory for octave packages feels very intrusive.

The typical process whenever I install my first package in a fresh octave installation seems to go something like this:

1) pkg install somepackage -forge
2) "Ah crap, it's gone and made an ugly 'octave' folder right in my home directory. (sigh). Delete. Delete. Delete"
3) pkg uninstall somepackage
4) Delete /home/user/octave
5) pkg prefix /home/user/.octave /home/user/.octave
6) pkg install somepackage -forge
7) (sigh)

I consider this to be a 'papercut' (as per the ubuntu philosophy on papercuts, i.e. one of those negative experiences which, while not functionality-breaking, are unnecessarily frustrating first-use experiences which negatively predispose the overall user experience from that point on)

I'm hoping for some discussion on whether others feel this is a significant enough annoyance or not. I note that on Windows the default folder is much more reasonable (but I understand why the same folder wouldn't work in the Linux hierarchy).

Acceptable solutions in my mind would be a more reasonable (w.r.t. unix filesystem philosophy) default prefix directory, e.g. ".octave" / ".octave/lib" etc, or a directory confirmation / warning before installation of the *first* package (i.e., similar to how Julia does it ).




Reply | Threaded
Open this post in threaded view
|

Re: Change default package directory from octave to .octave, or ask before first package installation

Mike Miller-4
On Mon, Aug 27, 2018 at 16:27:11 +0000, Tasos Papastylianou wrote:
> The current choice of default installation directory for octave
> packages feels very intrusive.

Agree.

> I'm hoping for some discussion on whether others feel this is a
> significant enough annoyance or not. I note that on Windows the
> default folder is much more reasonable (but I understand why the same
> folder wouldn't work in the Linux hierarchy).
>
> Acceptable solutions in my mind would be a more reasonable (w.r.t.
> unix filesystem philosophy) default prefix directory, e.g. ".octave" /
> ".octave/lib" etc, or a directory confirmation / warning before
> installation of the *first* package (i.e., similar to how Julia does
> it ).
I personally use the following configuration:

  ~/.local/lib/octave/${ver}/packages/
  ~/.local/share/octave/${ver}/packages/
  ~/.local/share/octave/${ver}/octave_packages  (cache file)

IMHO this is the most consistent with other programs and filesystem
conventions, as well as conveniently allowing different sets and builds
of packages for each Octave release (as a developer, I switch between
multiple Octave releases regularly).

BTW, the ${ver} variable in the names above is only "4.2" or "4.4",
since compiled oct functions are *usually* compatible with subsequent
bug fix releases.

Do you think Octave should change to use a default like this?

--
mike



signature.asc (849 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Change default package directory from octave to .octave, or ask before first package installation

avlas-2

El dilluns, 27 d’agost de 2018, a les 14:03:57 EDT, Mike Miller va escriure:

  On Mon, Aug 27, 2018 at 16:27:11 +0000, Tasos Papastylianou wrote:
  > The current choice of default installation directory for octave
  > packages feels very intrusive.
 
  Agree.
 
  > I'm hoping for some discussion on whether others feel this is a
  > significant enough annoyance or not. I note that on Windows the
  > default folder is much more reasonable (but I understand why the same
  > folder wouldn't work in the Linux hierarchy).
  >
  > Acceptable solutions in my mind would be a more reasonable (w.r.t.
  > unix filesystem philosophy) default prefix directory, e.g. ".octave" /
  > ".octave/lib" etc, or a directory confirmation / warning before
  > installation of the *first* package (i.e., similar to how Julia does
  > it ).
 
  I personally use the following configuration:
 
    ~/.local/lib/octave/${ver}/packages/
    ~/.local/share/octave/${ver}/packages/
    ~/.local/share/octave/${ver}/octave_packages  (cache file)
 
  IMHO this is the most consistent with other programs and filesystem
  conventions, as well as conveniently allowing different sets and builds
  of packages for each Octave release (as a developer, I switch between
  multiple Octave releases regularly).
 
  BTW, the ${ver} variable in the names above is only "4.2" or "4.4",
  since compiled oct functions are *usually* compatible with subsequent
  bug fix releases.
 
  Do you think Octave should change to use a default like this?
 
 
That would be a great default, in my opinion

--

Salva Ardid, PhD
Boston University




Reply | Threaded
Open this post in threaded view
|

Re: Change default package directory from octave to .octave, or ask before first package installation

Tasos Papastylianou
In reply to this post by Mike Miller-4
Hi Mike!
Yes, that sounds much more reasonable!

An info note at or before the very first install might also still be desirable, for people who aren't particularly familiar with the pkg prefix command or how packages work in general, e.g. something like

"You are installing your first octave package. The default installation directory is blah blah blah.
If you'd like to use something else, use the 'pkg prefix' command before installing, to specify a different directory. See 'help pkg' for details."

----
Tasos



From: Help-octave <help-octave-bounces+tpapastylianou=[hidden email]> on behalf of Mike Miller <[hidden email]>
Sent: 27 August 2018 11:03
To: [hidden email]
Subject: Re: Change default package directory from octave to .octave, or ask before first package installation
 
On Mon, Aug 27, 2018 at 16:27:11 +0000, Tasos Papastylianou wrote:
> The current choice of default installation directory for octave
> packages feels very intrusive.

Agree.

> I'm hoping for some discussion on whether others feel this is a
> significant enough annoyance or not. I note that on Windows the
> default folder is much more reasonable (but I understand why the same
> folder wouldn't work in the Linux hierarchy).
>
> Acceptable solutions in my mind would be a more reasonable (w.r.t.
> unix filesystem philosophy) default prefix directory, e.g. ".octave" /
> ".octave/lib" etc, or a directory confirmation / warning before
> installation of the *first* package (i.e., similar to how Julia does
> it ).

I personally use the following configuration:

  ~/.local/lib/octave/${ver}/packages/
  ~/.local/share/octave/${ver}/packages/
  ~/.local/share/octave/${ver}/octave_packages  (cache file)

IMHO this is the most consistent with other programs and filesystem
conventions, as well as conveniently allowing different sets and builds
of packages for each Octave release (as a developer, I switch between
multiple Octave releases regularly).

BTW, the ${ver} variable in the names above is only "4.2" or "4.4",
since compiled oct functions are *usually* compatible with subsequent
bug fix releases.

Do you think Octave should change to use a default like this?

--
mike