Bash
Bash is the GNU Project's shell. Bash is the Bourne Again SHell. Bash is an sh-compatible shell that incorporates useful features from the Korn shell (ksh) and C shell (csh). It is intended to conform to the IEEE POSIX P1003.2/ISO 9945.2 Shell and Tools standard. The improvements offered by Bash include: Command line editingUnlimited size command historyJob ControlShell Functions and AliasesIndexed arrays of unlimited sizeInteger arithmetic in any base from two to sixty-four The maintainer also has a bash page which includes Frequently-Asked-Questions. Downloading Bash Bash can be found on the main GNU ftp server: (via HTTP) and (via FTP). Documentation Documentation for Bash is available online, as is documentation for most GNU software. Mailing lists To ask for help about bash, bash programming or bash shell scripting please use the <help-bash@gnu.org> mailing list. Getting involved Development Translating Bash Maintainer Licensing
Puppet Labs: IT Automation Software for System Administrators
BASH Programming - Introduction HOW-TO: Conditionals
NextPreviousContents 6. Conditionals Conditionals let you decide whether to perform an action or not, this decision is taken by evaluating an expression. 6.1 Dry Theory Conditionals have many forms. Conditionals have other forms such as: if expression then statement1 else statement2. Yet another form of conditionals is: if expression1 then statement1 else if expression2 then statement2 else statement3. A word about syntax: The base for the 'if' constructions in bash is this: if [expression]; then code if 'expression' is true. fi 6.2 Sample: Basic conditional example if .. then #! The code to be executed if the expression within braces is true can be found after the 'then' word and before 'fi' which indicates the end of the conditionally executed code. 6.3 Sample: Basic conditional example if .. then ... else #! 6.4 Sample: Conditionals with variables #!
d3.js
Bash by example, Part 2
Let's start with a brief tip on handling command-line arguments, and then look at bash's basic programming constructs. Accepting arguments In the sample program in the introductory article, we used the environment variable "$1", which referred to the first command-line argument. Similarly, you can use "$2", "$3", etc. to refer to the second and third arguments passed to your script. Here's an example: #! The example is self explanatory except for three small details. Sometimes, it's helpful to refer to all command-line arguments at once. Back to top Bash programming constructs If you've programmed in a procedural language like C, Pascal, Python, or Perl, then you're familiar with standard programming constructs like "if" statements, "for" loops, and the like. Conditional love If you've ever programmed any file-related code in C, you know that it requires a significant amount of effort to see if a particular file is newer than another. if [ -z "$myvar" ] then echo "myvar is not defined" fi #! #!
★ Pour ne plus être en REST, comprendre cette architecture
Depuis quelques mois, j'apprends j'essaye d'apprendre REST et j'ai lu de nombreuses pages sans pour autant trouver d'explication simple, à la portée de tous. Du coup quand j'essaye d'expliquer les mécanismes et les avantages professionnellement, c'est pas toujours convaincant... et je voulais justement écrire un petit billet pour mettre tout ça au clair. Et puis je suis récemment tombé sur une série d'explications par Softies on Rails se basant sur des exemples concrets. En voici la traduction chronologique. Comprendre les ressources D'une certaine manière, apprendre REST fut très difficile pour moi. Si vous essayez de comprendre REST, cette série est faite pour vous. Les experts en HTTP, HTML et REST pourraient chercher la petite bête avec ma terminologie simplifiée me permettant d'aller droit au but. Premier point Commençons par le commencement. Et c'est à peu près tout. Deuxième point Remarquez comme j'ai glissé le mot « ressource » alors que vous ne l'attendiez pas. Troisième point Ugh.
Bash by example, Part 1
Fundamental programming in the Bourne again shell (bash) Daniel RobbinsPublished on March 01, 2000 You might wonder why you ought to learn Bash programming. Well, here are a couple of compelling reasons: You're already running it If you check, you'll probably find that you are running bash right now. You're already using it Not only are you already running bash, but you're actually interacting with bash on a daily basis. Bash confusion Learning bash the wrong way can be a very confusing process. While this may be somewhat disappointing to novices, the standard bash documentation can't be all things to all people, and caters towards those already familiar with shell programming in general. That's where this series comes in. Environment variables Under bash and almost all other shells, the user can define environment variables, which are stored internally as ASCII strings. The standard way to define an environment variable under bash is: Quoting specifics dirname and basename Command substitution
Comprendre les APIs
Pomme d’api, apiculture, Aisne Plastique Industrie, api birthday ? Vous n’y êtes pas… La notion que je souhaite aborder aujourd’hui est celle d’Application Programming Interface. Qu’est-ce donc qu’une API ? A quoi cela peut-il servir ? Définition La plupart des définitions disponibles aujourd’hui sur le web abordent la notion d’API par sa dimension technique : on apprend ainsi sur wikipedia qu’une API est « un ensemble de fonctions, procédures ou classes mises à disposition par une bibliothèque logicielle, un système d’exploitation ou un service ». Je vous propose de dépasser ces aspects techniques et de vous livrer les définitions suivantes : Une API, c’est ce qui permet à deux systèmes informatiques totalement indépendants de se parler de façon automatique. Quelques exemples simples : Les APIs SMS , comme celle d’Orange, sont proposées par tous les opérateurs : elles vous permettent de savoir comment envoyer de façon automatisée des campagnes de SMS. A quoi cela sert-il ? Conclusion :