From: Pavel Usischev <usischev@gmail.com> To: ALT Linux Community <community@lists.altlinux.org> Subject: Re: [Comm] sh - bash Date: Sun, 15 Oct 2006 02:50:01 +0400 Message-ID: <45316999.9080600@gmail.com> (raw) In-Reply-To: <egrmje$imn$1@sea.gmane.org> Artem Zolochevskiy пишет: > Всё, что я когда-то уяснил, это то, что сперва был sh (который чего-то там > не умел) а затем стал bash, который сейчас повсеместно и используется и > чего-то там умеет, чего не умел sh Ну это не то чтобы совсем так :) Совместимы с sh, насколько я знаю, все используемые сейчас шеллы. А это не только bash, но и стандартный во FreeBSD tcsh, и очень мощный zsh. > Собственно вопрос относительно написания скриптов > Отчего же тогда вижу везде #!/bin/sh (в стартовых сценариях итп) - если этот > sh такой старый и неумека? Как раз для переносимости скрипта. В ALT /bin/sh -- это особый вариант bash, в других системах это вполне может быть другой шелл, а bash вообще может отсутствовать. > Ну и, если можно, пример можете привести где употребление > #!/bin/sh или #!/bin/bash может сказаться на работоспособности скрипта. > Т.е. какая такая фича может быть в скрипте, что при использовании #!/bin/sh > он работать не будет. Об отличиях bash от изначального Bourne Shell можно почитать, дав команду: info bash 'Major Differences From The Bourne Shell' Однако, насколько я понял, в ALT /bin/sh будет вести себя так же, как /bin/bash (возможно, я просто как-то не так проверял). -- С уважением, Павел Усищев
next prev parent reply other threads:[~2006-10-14 22:50 UTC|newest] Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top 2006-10-14 21:57 Artem Zolochevskiy 2006-10-14 22:27 ` Alexey Rusakov 2006-10-15 5:41 ` Artem Zolochevskiy 2006-10-15 6:13 ` Alexey Rusakov 2006-10-15 8:41 ` Andrey Rahmatullin 2006-10-15 8:56 ` Artem Zolochevskiy 2006-10-15 9:03 ` Andrey Rahmatullin 2006-10-14 22:50 ` Pavel Usischev [this message] 2006-10-15 5:53 ` Artem Zolochevskiy 2006-10-15 5:57 ` Artem Zolochevskiy 2006-10-15 7:26 ` Sergey Vlasov 2006-10-15 7:43 ` Artem Zolochevskiy 2006-10-15 11:31 ` Dmitry V. Levin 2006-10-18 12:01 ` Fr. Br. George 2006-10-15 17:55 ` [Comm] heirloom toolchest Michael Shigorin 2006-10-15 10:55 ` [Comm] sh - bash Maksim Otstavnov 2006-10-15 17:52 ` Michael Shigorin 2006-10-15 17:48 ` Michael Shigorin
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=45316999.9080600@gmail.com \ --to=usischev@gmail.com \ --cc=community@lists.altlinux.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
ALT Linux Community general discussions This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 community community/ http://lore.altlinux.org/community \ mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com public-inbox-index community Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.community AGPL code for this site: git clone https://public-inbox.org/public-inbox.git