Dwarf Fortress starting during apt-get upgrade
askubuntu.com
askubuntu.com
Some cases are less clear-cut, however. For example, the Debian 'nodejs' package installs node.js binary as /usr/bin/nodejs and not /usr/bin/node because it conflicts with another package: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=614907#108
And let's not forget rename(1) from util-linux versus the Perl rename(1)...
`if LC_ALL=C BLOCKSIZE= df --portability $DATADIR/. | tail -n 1 | awk '{ exit ($4>1000) }'; then`
There's `df` being called without the full path and that's what would be spawning Dwarf Fortress.
Many use aliases only to specify default command parameters, but it works just as well to provide an execution path, like, in this case:
alias df=/home/my_user/games/dwarf_fortress/df
It would only be executed in interactive sessions, this way, which should guard well enough against system code interpreting it.Of course, this still means user can't use system's `df` easily, but I guess they don't use it anyway since they did not realize the problem until that upgrade.
\df
There you go.alias freespace=/bin/df
Though then they'd have to uninstall FreeSpace 2.
My point was more to show a way this particular user could have achieved the same result without their problem.
Plus, we can't expect users to know all the system tools, this is a good way to isolate "user space" from "system space", so I guess taking the habit to use aliases rather than putting things in `/usr/local/bin/` makes sense by itself (except when we want indeed to override an executable provided by system, or we want indeed to provide a new system tool).
(This memory is a few years out of date.)
Always takes me a couple of seconds to realize what's going on...
But putting a whole game in place of a standard Linux util sounds like awesome menace, reminds me of the sl command (steam locomotive) which you can install on Debian (and maybe other distros?) for those who may typo ls they'll get a fun surprise :)
However, I can see how for a beginner programmer system("pause"); is more intuitive than printf/_getch() combo. Especially if said programmer is already familiar with windows shell and its commands.
[1] http://web.archive.org/web/20120826174233/http://diden.net/i...
Do you also write "if /usr/bin/[ $? != 0 ]; then ..." ?
getconf PATH
to set the path to the one that guarantees that.* http://pubs.opengroup.org/onlinepubs/9699919799/utilities/ge...
* http://pubs.opengroup.org/onlinepubs/9699919799/functions/co...
* http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/uni...
But actually, it would be cool to have some kind of warning, like a POSIX linter that warns the user something broke the standard, and they can decide to ignore it and never hear about it again. I'm not a big fan of linters, usually, but it would make sense for end users tweaking their system.
well, goodbye productivity.
I wonder if I can run it on a production server without anyone noticing...
This means either having separate 32bit libraries (typical for closed source applications shipping together with their libraries) or having multiarch libraries (as modern linux distros do).