Talk:Bash

From Gentoo Wiki
Jump to:navigation Jump to:search
Note
This is a Talk page - please see the documentation about using talk pages. Add newer comments below older ones, sign comments using four tildes (~~~~), and indent successive comments with colons (:). Add new sections at the bottom of the page, under a heading (== ==). Please remember to mark sections as "open for discussion" using {{talk|open}}, so they will show up in the list of open discussions.

About deletion content

Talk status
This discussion is done as of 2021-12-20.

User Ormaaj delete some content of articles Bash and Vim. Logs can be found on this page. Some of changes definitelly must be discussed on proper talk pages (this page and Talk:Vim).

Details, that I want point out:

  • Currently part of deletion rejected, but old deletion is not.
  • Redefining rm, cp, mv commands via bash functions instead alias looks like less common approach. Aliases uses in default Gentoo bashrc. I'm not sure that current bashrc example better than old (before Ormaaj changes).
  • All last Bash article changes (with partial reversion) is here. I'm not so experienced user, so as to estimate variables-related changes, but simply point for more experienced participants, that has been changed.

I not assert that pointed changes is bad, but request to verify and discuss it.

--Totktonada (talk) 13:57, 22 March 2014 (UTC)

The difficulty is this is an introductory article which can't possibly go into the necessary detail to describe every best practice and pitfall.
Aliases are one good example. They are widely misused and should be avoided unless there's a specific reason to use them. Therefore, aliases probably aren't important enough to deserve any discussion considering the absence of more important concepts that should take precedence. I would rather omit the section and point advanced users to better resources than recommend their use in an incomplete segment.
The bash manual recommends the same: "The rules concerning the definition and use of aliases are somewhat confusing [...] For almost every purpose, aliases are superseded by shell functions". Or feel free to search the bash mailing list archives for decades of discussion that all pretty much boils down to "just don't use them".
The section labeled "subshells" doesn't actually describe subshells, mention the thing it's actually trying to describe (command substitutions), or manage give a single example that doesn't demonstrate a poor practice. I don't care whether it "just gets the job done". An overview article should not contain any poor practices, because people will adapt techniques for other problems without doing the proper research. This applies to all programming languages.
The issue of whether to recommend ABS is controversial and has been discussed at length in various newsgroups and mailing lists. The problem is similar to that of w3schools. The general consensus is that while it contains some useful information, it requires someone with experience to separate the good from the bad. My preference is to omit it from recommended reading lists. If it must be included, I would definitely not put it at the top of the list.

Ormaaj (talk) 23:41, 22 March 2014 (UTC)

I agree that introductory article doesn't contain advanced details. But, IMHO, things that is simultaneously common and poor necessary to mention, for example in footnote. Consider situation: aliases used in my default Gentoo /etc/bash/bashrc, but avoided in Gentoo wiki article without any notes. Reasonable conclusion is that article approach can consists pitfalls. So I point, that situation with common and possibly poor details must be, IMHO, shortly described (ideally with some kind of pointers for further reading about problem). As least article must mention all approaches, that substitute common.
Example with ABS Guide very similar to aliases situations; it is common suggestion and simple removing them has no positive effect for readers. In my opinion, ABS Guide must be included, but with appropriate notes.
I not understand, what bad with $() substitution itself, not in terminology. Can you explain this moment? And about terminology: I agree, subshell is ( list; ), not $( list; ). I was fix term in article.
So I vote for short in-text notes, footnotes or small separate section; don't not know what form better.
--Totktonada (talk) 10:34, 23 March 2014 (UTC)