Hi,
thanks Jeroen for raising this question. Note that `sage -i` appears both
in `sage -h` and `sage -advanced`, which might explain why its status is
not well defined (user interface vs atomic dev tool). So, the question is
about splitting the two features.
From the user point of view, (A) is definitely better than (B) or (C).
Having a high-level, easy to remember syntax will survive to packaging
changes, while the direct use of a makefile might not be natural if we
move to a packaging system like conda (say). Those things should remain
behind the scenes (including having to be in the right directory).
Actually, i do not see why (A) involves more complexity than (B). We
could get both benefits without much work with (D):
- move the current low-level `sage -i` to, say, `sage -p` (which
automatically includes `sage -p -c -f` and remains consistent with
`sage -b` and `sage --docbuild`, so that we keep all the benefits of
(B)). Replace `sage -i` with `sage -p` in `sage -advanced`.
- consider `sage -i` as the user interface to the current packaging
system. For now, it could just call `make`, later it could call some
conda/hashdist/whatever command transparently.
Concerning the "change of behaviour", i guess nobody except a few
developpers know that `sage -i` does only a partial job. Having `sage -i`
installing the dependencies should not be considered as a change of
behaviour, but as an improvement towards the (unchanged) expected
behaviour ("something that just works to install a package", from
anywhere, without bothering about dependencies).
There are easy and hard to remember notations. I want to plead that the
easy ones should be reserved for the end users and high-level stable
interfaces. The `sage -i` command is definitely more natural than `sage
-m` to install a package (`sage -i` is about what is done, `sage -m` is
about how it is done). So, as i explained before, i prefer (A) or (D) from
this point of view, see:
(A) users: `sage -i pkg`
devs : `sage -i --no-dependencies pkg`
todo : boring preparsing
(B) users: `sage -m pkg`
devs : `sage -i pkg`
todo : almost nothing but user documentation
(C) users: `cd $SAGE_ROOT ; make pkg`
devs : `sage -i pkg`
todo : documentation and user support (please join
ask.sagemath.org)
(D) users: `sage -i pkg`
devs : `sage -p pkg`
todo : almost nothing but dev documentation
Perhaps some (very few) of us will have to change our scripts to get
adapted to the fact that `sage -i` now installs dependencies, but at least
we are able to to this easily. Explaining to every user how to use make
requires much more work, especially if we have to teach another tool while
eventually changing the packaging system.
Concerning `sage -f`, isn't it more about rebuilding "backward
dependencies" than dependencies ?
Ciao,
Thierry