Evolution of Unix course

This commit is contained in:
Eric Coissac
2025-10-31 14:19:31 +01:00
parent 1d0db893f1
commit d49592c5d4
18 changed files with 9652 additions and 24 deletions

View File

@@ -0,0 +1,142 @@
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Unix Essentials — Bash Exercises\n",
"\n",
"This notebook contains short hands-on Bash exercises.\n",
"Each exercise has a hidden solution that can be unfolded when needed."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Exercise 1 Listing and Filtering Files\n",
"\n",
"Create three files and list only those whose name ends with `.log`."
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# your work here\n",
"touch report.log notes.txt errors.log\n",
"# list files ending with .log"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"jupyter": {
"source_hidden": true,
"outputs_hidden": true
}
},
"outputs": [],
"source": [
"# Solution\n",
"ls *.log"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Exercise 2 Redirecting Output\n",
"\n",
"List the `/etc` directory and save the results in a file named `listing.txt`, then display the first five lines of that file."
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# your work here\n",
"# 1. list /etc\n",
"# 2. redirect output to listing.txt\n",
"# 3. show first five lines"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"jupyter": {
"source_hidden": true,
"outputs_hidden": true
}
},
"outputs": [],
"source": [
"# Solution\n",
"ls /etc > listing.txt\n",
"head -5 listing.txt"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Exercise 3 Using a For Loop\n",
"\n",
"Write a loop that prints the line count of each `.txt` file in the current directory."
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# your work here\n",
"# hint: use wc -l"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"jupyter": {
"source_hidden": true,
"outputs_hidden": true
}
},
"outputs": [],
"source": [
"# Solution\n",
"for f in *.txt; do\n",
" echo \"$f: $(wc -l < \"$f\") lines\"\n",
"done"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"All solutions are hidden by default (`source_hidden: true`). Students can unfold them in Jupyters interface to compare with their own answers."
]
}
],
"metadata": {
"kernelspec": {
"display_name": "Bash",
"language": "bash",
"name": "bash"
},
"language_info": {
"name": "bash"
}
},
"nbformat": 4,
"nbformat_minor": 5
}

View File

@@ -8,6 +8,7 @@ RUN apt-get update && apt-get install -y \
r-base r-base-dev \
libcurl4-openssl-dev libssl-dev libxml2-dev \
build-essential git curl \
texlive-xetex texlive-fonts-recommended texlive-plain-generic \
&& apt-get clean && rm -rf /var/lib/apt/lists/*
# Install R kernel + useful packages

View File

@@ -0,0 +1,148 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg width="100%" height="100%" viewBox="0 0 520 73" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;">
<g id="Calque-1" serif:id="Calque 1" transform="matrix(0.338388,0,0,0.338388,6.658634,-44.799997)">
<g id="Plan-de-travail1" serif:id="Plan de travail1" transform="matrix(12.595896,0,0,2.955191,-7740.961754,-1114.698045)">
<rect x="613" y="422" width="122" height="73" style="fill:none;"/>
<g transform="matrix(1,0,0,1,-0.234615,0)">
<g id="text3410-4" transform="matrix(0.085357,0,0,0.363816,611.32066,369.428742)">
<g transform="matrix(1,0,0,1,739.95099,305.45532)">
<g transform="matrix(17.731146,0,0,17.731146,83.21864,0)">
</g>
<text x="0px" y="0px" style="font-family:'TimesNewRomanPSMT', 'Times New Roman', serif;font-size:17.731px;">command 2</text>
</g>
</g>
<g id="text3414-7" transform="matrix(0.085357,0,0,0.363816,610.851429,369.428742)">
<g transform="matrix(1,0,0,1,877.74036,305.45532)">
<g transform="matrix(17.731146,0,0,17.731146,52.215108,0)">
</g>
<text x="0px" y="0px" style="font-family:'TimesNewRomanPSMT', 'Times New Roman', serif;font-size:17.731px;">options</text>
</g>
</g>
<g id="text3418-2" transform="matrix(0.085357,0,0,0.363816,610.382198,369.428742)">
<g transform="matrix(1,0,0,1,1039.2732,305.45532)">
<g transform="matrix(17.731146,0,0,17.731146,73.539235,0)">
</g>
<text x="0px" y="0px" style="font-family:'TimesNewRomanPSMT', 'Times New Roman', serif;font-size:17.731px;">ar<tspan x="13.454px 22.32px " y="0px 0px ">gu</tspan>ments</text>
</g>
</g>
<g id="text3422-2" transform="matrix(0.085357,0,0,0.363816,610.382198,369.428742)">
<g transform="matrix(1,0,0,1,1246.8026,305.45532)">
<g transform="matrix(17.731146,0,0,17.731146,83.694818,0)">
</g>
<text x="0px" y="0px" style="font-family:'TimesNewRomanPSMT', 'Times New Roman', serif;font-size:17.731px;">redirections</text>
</g>
</g>
<g transform="matrix(0.085357,0,0,0.363816,614.37066,369.428742)">
<g id="text3410" transform="matrix(1,0,0,1,23.641528,0)">
<g transform="matrix(1,0,0,1,7.861387,305.45532)">
<g transform="matrix(19.240499,0,0,19.240499,90.302574,0)">
</g>
<text x="0px" y="0px" style="font-family:'TimesNewRomanPSMT', 'Times New Roman', serif;font-size:19.24px;">command 1</text>
</g>
</g>
<g id="text3414">
<g transform="matrix(1,0,0,1,155.65079,305.45532)">
<g transform="matrix(17.731146,0,0,17.731146,52.215108,0)">
</g>
<text x="0px" y="0px" style="font-family:'TimesNewRomanPSMT', 'Times New Roman', serif;font-size:17.731px;">options</text>
</g>
</g>
<g id="text3418">
<g transform="matrix(1,0,0,1,317.18356,305.45532)">
<g transform="matrix(17.731146,0,0,17.731146,73.539235,0)">
</g>
<text x="0px" y="0px" style="font-family:'TimesNewRomanPSMT', 'Times New Roman', serif;font-size:17.731px;">ar<tspan x="13.454px 22.32px " y="0px 0px ">gu</tspan>ments</text>
</g>
</g>
<g id="text3422">
<g transform="matrix(1,0,0,1,524.71301,305.45532)">
<g transform="matrix(17.731146,0,0,17.731146,83.694818,0)">
</g>
<text x="0px" y="0px" style="font-family:'TimesNewRomanPSMT', 'Times New Roman', serif;font-size:17.731px;">redirections</text>
</g>
</g>
</g>
</g>
</g>
<g id="rect2575-9" transform="matrix(1,0,0,1.060913,-0,-15.062179)">
<rect x="127.612" y="199.004" width="138.123" height="48.024" style="fill:rgb(193,251,201);stroke:black;stroke-width:2.49px;"/>
<g transform="matrix(2.955191,0,0,2.785516,-249.505733,-355.324777)">
<g transform="matrix(0.674811,0,0,1,42.776636,0)">
<g transform="matrix(12,0,0,12,195.080696,211.824152)">
</g>
<text x="131.544px" y="211.824px" style="font-family:'AndaleMono', 'Andale Mono', monospace;font-size:12px;">-i -text</text>
</g>
</g>
</g>
<g id="rect2575-9-8" transform="matrix(1,0,0,1.060913,-0,-15.062179)">
<rect x="273.456" y="199.264" width="203.94" height="47.504" style="fill:rgb(252,255,206);stroke:black;stroke-width:3.01px;"/>
<g transform="matrix(2.955191,0,0,2.785516,-534.658449,-355.788565)">
<g transform="matrix(0.674811,0,0,1,94.614922,0)">
<g transform="matrix(12,0,0,12,341.36142,211.990653)">
</g>
<text x="290.953px" y="211.991px" style="font-family:'AndaleMono', 'Andale Mono', monospace;font-size:12px;">pattern</text>
</g>
</g>
</g>
<g id="rect2575" transform="matrix(1,0,0,1.060913,-0,-15.062179)">
<rect x="33.25" y="198.758" width="88.119" height="48.515" style="fill:rgb(174,183,222);stroke:black;stroke-width:2px;"/>
<g transform="matrix(2.955191,0,0,2.785516,-65.010532,-354.886201)">
<g transform="matrix(0.674811,0,0,1,11.710337,0)">
<g transform="matrix(12,0,0,12,72.016671,211.666702)">
</g>
<text x="36.011px" y="211.667px" style="font-family:'AndaleMono', 'Andale Mono', monospace;font-size:12px;">egrep</text>
</g>
</g>
</g>
<g id="rect2575-9-8-2" transform="matrix(1,0,0,1.060913,-0,-15.062179)">
<rect x="482.428" y="199.305" width="215.738" height="47.421" style="fill:rgb(244,210,255);stroke:black;stroke-width:3.09px;"/>
<g transform="matrix(2.955191,0,0,2.785516,-943.239125,-355.862789)">
<g transform="matrix(0.674811,0,0,1,161.639396,0)">
<g transform="matrix(12,0,0,12,561.872754,212.017297)">
</g>
<text x="497.062px" y="212.017px" style="font-family:'AndaleMono', 'Andale Mono', monospace;font-size:12px;">&lt; my_data</text>
</g>
</g>
</g>
<g id="text9483">
<g transform="matrix(1,0,0,1,711.88123,272.16415)">
<text x="0px" y="0px" style="font-family:'Helvetica';font-size:144px;fill:rgb(255,0,0);">|</text>
</g>
</g>
<g id="rect2575-9-87" transform="matrix(1,0,0,1.060913,0,-15.062179)">
<rect x="849.702" y="199.004" width="138.123" height="48.024" style="fill:rgb(193,251,201);stroke:black;stroke-width:2.49px;"/>
<g transform="matrix(2.955191,0,0,2.785516,-1661.328781,-355.324777)">
<g transform="matrix(12,0,0,12,880.2722,211.824152)">
</g>
<text x="865.87px" y="211.824px" style="font-family:'AndaleMono', 'Andale Mono', monospace;font-size:12px;">-l</text>
</g>
</g>
<g id="rect2575-9-8-8" transform="matrix(1,0,0,1.060913,0,-15.062179)">
<rect x="995.545" y="199.264" width="203.94" height="47.504" style="fill:rgb(252,255,206);stroke:black;stroke-width:3.01px;"/>
</g>
<g id="rect2575-7" transform="matrix(1,0,0,1.060913,0,-15.062179)">
<rect x="755.34" y="198.758" width="88.119" height="48.515" style="fill:rgb(174,183,222);stroke:black;stroke-width:2px;"/>
<g transform="matrix(2.955191,0,0,2.785516,-1476.83352,-354.886201)">
<g transform="matrix(12,0,0,12,777.450109,211.666702)">
</g>
<text x="763.048px" y="211.667px" style="font-family:'AndaleMono', 'Andale Mono', monospace;font-size:12px;">wc</text>
</g>
</g>
<g id="rect2575-9-8-2-7" transform="matrix(1.219169,0,0,1.060913,-263.993051,-15.062179)">
<rect x="1204.518" y="199.305" width="215.738" height="47.421" style="fill:rgb(244,210,255);stroke:black;stroke-width:3.09px;"/>
<g transform="matrix(2.423939,0,0,2.785516,-1715.159199,-355.862789)">
<g transform="matrix(12,0,0,12,1292.226228,212.017297)">
</g>
<text x="1205.812px" y="212.017px" style="font-family:'AndaleMono', 'Andale Mono', monospace;font-size:12px;">&gt; my_results</text>
</g>
</g>
<g id="text2571-1">
</g>
<g id="text3410-3">
<g transform="matrix(1,0,0,1,579.78821,151.48306)">
<text x="0px" y="0px" style="font-family:'Helvetica';font-size:24px;">tube de jonction stdout &gt; stdin</text>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 9.6 KiB

View File

@@ -0,0 +1,167 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="210mm"
height="297mm"
id="svg2"
sodipodi:version="0.32"
inkscape:version="0.46+devel"
sodipodi:docname="commande.svg"
inkscape:output_extension="org.inkscape.output.svg.inkscape">
<defs
id="defs4">
<inkscape:perspective
sodipodi:type="inkscape:persp3d"
inkscape:vp_x="0 : 526.18109 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_z="744.09448 : 526.18109 : 1"
inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
id="perspective10" />
<inkscape:perspective
id="perspective2584"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective2605"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective2626"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="1.01"
inkscape:cx="348.57747"
inkscape:cy="757.62376"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1440"
inkscape:window-height="823"
inkscape:window-x="0"
inkscape:window-y="22" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Calque 1"
inkscape:groupmode="layer"
id="layer1">
<rect
style="fill:#c1fbc9;fill-opacity:1;stroke:#000000;stroke-width:2.49125432999999985;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2575-9"
width="138.1226"
height="48.023598"
x="127.61195"
y="203.41969" />
<rect
style="fill:#fcffce;fill-opacity:1;stroke:#000000;stroke-width:3.01075077000000002;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2575-9-8"
width="203.93974"
height="47.504101"
x="273.45587"
y="203.67944" />
<rect
style="fill:#aeb7de;fill-opacity:1;stroke:#000000;stroke-width:2;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2575"
width="88.118813"
height="48.514851"
x="33.250221"
y="203.17406" />
<rect
style="fill:#f4d2ff;fill-opacity:1;stroke:#000000;stroke-width:3.09390211000000015;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2575-9-8-2"
width="215.73779"
height="47.420948"
x="482.42813"
y="203.72101" />
<text
xml:space="preserve"
style="font-size:30.15070534px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Courier;-inkscape-font-specification:Courier"
x="49.616787"
y="194.01952"
id="text2571"
sodipodi:linespacing="125%"
transform="scale(0.82146852,1.2173321)"><tspan
sodipodi:role="line"
id="tspan2573"
x="49.616787"
y="194.01952">egrep -i --text monficher.txt &gt; mesresultats</tspan></text>
<text
xml:space="preserve"
style="font-size:28px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="15.861387"
y="302.57678"
id="text3410"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3412"
x="15.861387"
y="302.57678">commande</tspan></text>
<text
xml:space="preserve"
style="font-size:28px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="155.65079"
y="302.57678"
id="text3414"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3416"
x="155.65079"
y="302.57678">options</tspan></text>
<text
xml:space="preserve"
style="font-size:28px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="317.18356"
y="302.57678"
id="text3418"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3420"
x="317.18356"
y="302.57678">arguments</tspan></text>
<text
xml:space="preserve"
style="font-size:28px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="524.71301"
y="302.57678"
id="text3422"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3424"
x="524.71301"
y="302.57678">redirections</tspan></text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 6.6 KiB

File diff suppressed because it is too large Load Diff

After

Width:  |  Height:  |  Size: 146 KiB

File diff suppressed because it is too large Load Diff

After

Width:  |  Height:  |  Size: 110 KiB

View File

@@ -0,0 +1,55 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" width="900" height="400" viewBox="0 0 900 400">
<!-- Dégradés pour les dossiers -->
<defs>
<linearGradient id="folderGradient" x1="0%" y1="0%" x2="0%" y2="100%">
<stop offset="0%" stop-color="#4a8fe7"/>
<stop offset="100%" stop-color="#2a6fc9"/>
</linearGradient>
</defs>
<!-- Dossier racine "/" -->
<g transform="translate(50, 150)">
<path d="M 0,0 L 80,0 L 80,60 Q 80,80 60,80 L 20,80 Q 0,80 0,60 Z" fill="url(#folderGradient)" stroke="#2a6fc9" stroke-width="2"/>
<text x="40" y="100" text-anchor="middle" font-family="Arial" font-size="14" fill="#333">/</text>
</g>
<!-- Dossier "home" -->
<g transform="translate(180, 100)">
<path d="M 0,0 L 80,0 L 80,60 Q 80,80 60,80 L 20,80 Q 0,80 0,60 Z" fill="url(#folderGradient)" stroke="#2a6fc9" stroke-width="2"/>
<text x="40" y="100" text-anchor="middle" font-family="Arial" font-size="14" fill="#333">home</text>
</g>
<!-- Dossier "etc" -->
<g transform="translate(180, 200)">
<path d="M 0,0 L 80,0 L 80,60 Q 80,80 60,80 L 20,80 Q 0,80 0,60 Z" fill="url(#folderGradient)" stroke="#2a6fc9" stroke-width="2"/>
<text x="40" y="100" text-anchor="middle" font-family="Arial" font-size="14" fill="#333">etc</text>
</g>
<!-- Dossier "usr" -->
<g transform="translate(180, 300)">
<path d="M 0,0 L 80,0 L 80,60 Q 80,80 60,80 L 20,80 Q 0,80 0,60 Z" fill="url(#folderGradient)" stroke="#2a6fc9" stroke-width="2"/>
<text x="40" y="100" text-anchor="middle" font-family="Arial" font-size="14" fill="#333">usr</text>
</g>
<!-- Fichiers -->
<g transform="translate(350, 70)">
<rect x="0" y="0" width="70" height="50" rx="3" fill="#f0f0f0" stroke="#ccc" stroke-width="1"/>
<text x="35" y="30" text-anchor="middle" font-family="Arial" font-size="12" fill="#333">grep</text>
</g>
<g transform="translate(350, 170)">
<rect x="0" y="0" width="70" height="50" rx="3" fill="#f0f0f0" stroke="#ccc" stroke-width="1"/>
<text x="35" y="30" text-anchor="middle" font-family="Arial" font-size="12" fill="#333">ls</text>
</g>
<!-- Connexions -->
<path d="M 130,180 L 180,180" stroke="#2a6fc9" stroke-width="1" fill="none"/>
<path d="M 130,280 L 180,280" stroke="#2a6fc9" stroke-width="1" fill="none"/>
<path d="M 130,380 L 180,380" stroke="#2a6fc9" stroke-width="1" fill="none"/>
<path d="M 260,130 L 350,100" stroke="#ccc" stroke-width="1" fill="none"/>
<path d="M 260,230 L 350,200" stroke="#ccc" stroke-width="1" fill="none"/>
</svg>

After

Width:  |  Height:  |  Size: 2.5 KiB

View File

@@ -0,0 +1,343 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<!--
Created By Andrew Fitzsimon.
Much of this document has been manually cleaned and crafted in a text editor so that only the colour definitions and basic presentation related data remain in the XML.
Changes to this document may compromise the structure of this palette.
-->
<svg
version="1.0"
x="00"
y="00"
width="128"
height="128"
id="Etiquette"
sodipodi:version="0.32"
inkscape:version="0.40"
sodipodi:docname="file-manager.svg"
sodipodi:docbase="/usr/share/icons/etiqueta/scalable/apps"
xmlns="http://www.w3.org/2000/svg"
xmlns:cc="http://web.resource.org/cc/"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:xlink="http://www.w3.org/1999/xlink">
<metadata
id="About">
<rdf:RDF
id="RDF232">
<cc:Work
rdf:about=""
id="Work233">
<dc:format
id="format234">image/svg+xml</dc:format>
<dc:type
id="type236"
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:creator
id="creator1291">
<cc:Agent
id="Agent1292">
<dc:title
id="title1293">Andrew Fitzsimon</dc:title>
</cc:Agent>
</dc:creator>
<dc:date
id="date1295">2004-12-25</dc:date>
<dc:title
id="title1297">Etiquette Icon</dc:title>
<cc:license
id="license1299"
rdf:resource="http://creativecommons.org/licenses/by/2.0/" />
<dc:rights
id="rights1308">
<cc:Agent
id="Agent1309">
<dc:title
id="title1310">Andrew Fitzsimon</dc:title>
</cc:Agent>
</dc:rights>
</cc:Work>
<cc:License
rdf:about="http://creativecommons.org/licenses/by/2.0/"
id="License1300">
<cc:permits
rdf:resource="http://web.resource.org/cc/Reproduction"
id="permits1301" />
<cc:permits
rdf:resource="http://web.resource.org/cc/Distribution"
id="permits1302" />
<cc:requires
rdf:resource="http://web.resource.org/cc/Notice"
id="requires1303" />
<cc:requires
rdf:resource="http://web.resource.org/cc/Attribution"
id="requires1304" />
<cc:prohibits
rdf:resource="http://web.resource.org/cc/CommercialUse"
id="prohibits1305" />
<cc:permits
rdf:resource="http://web.resource.org/cc/DerivativeWorks"
id="permits1306" />
<cc:requires
rdf:resource="http://web.resource.org/cc/ShareAlike"
id="requires1307" />
</cc:License>
</rdf:RDF>
</metadata>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="0"
inkscape:zoom="4.0000000"
inkscape:cx="59.853201"
inkscape:cy="30.487717"
inkscape:window-width="769"
inkscape:window-height="853"
inkscape:window-x="163"
inkscape:window-y="26"
inkscape:current-layer="Etiquette"
showgrid="true"
gridspacingx="8.0000000pt"
gridspacingy="8.0000000pt"
gridoriginy="0.0000000pt"
gridoriginx="0pt"
inkscape:grid-points="false"
gridtolerance="40pt"
showborder="true"
inkscape:grid-bbox="false"
gridcolor="#ffffff"
gridopacity="0.0000000"
gridempspacing="14"
gridempcolor="#3f3fff"
gridempopacity="0.0000000" />
<defs
id="Gradients">
<linearGradient
inkscape:collect="always"
id="linearGradient92">
<stop
style="stop-color:#000000;stop-opacity:1;"
offset="0"
id="stop93" />
<stop
style="stop-color:#000000;stop-opacity:0;"
offset="1"
id="stop94" />
</linearGradient>
<linearGradient
id="3DShadowGradient">
<stop
style="stop-color:#565248;stop-opacity:0.50000000;"
offset="0.0000000"
id="stop3933" />
<stop
style="stop-color:#565248;stop-opacity:0;"
offset="1"
id="stop3934" />
</linearGradient>
<radialGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="radialGradient2970"
gradientUnits="userSpaceOnUse"
cx="25.912205"
cy="175.83524"
fx="25.459438"
fy="142.80988"
r="56.143108" />
<linearGradient
id="Basic3DDarkGradient">
<stop
style="stop-color:#fff9e7;stop-opacity:0.77966100;"
offset="0.0000000"
id="stop3929" />
<stop
style="stop-color:#807d74;stop-opacity:0;"
offset="1"
id="stop3930" />
</linearGradient>
<linearGradient
id="MaterialSoftShadow">
<stop
style="stop-color:#000000;stop-opacity:0.215;"
offset="0"
id="stop2619" />
<stop
style="stop-color:#000000;stop-opacity:0.098;"
offset="0.50000000"
id="stop2621" />
<stop
style="stop-color:#000000;stop-opacity:0;"
offset="1"
id="stop2620" />
</linearGradient>
<linearGradient
id="WhiteTransparent">
<stop
style="stop-color:#ffffff;stop-opacity:1;"
offset="0"
id="stopWhiteFull" />
<stop
style="stop-color:#ffffff;stop-opacity:0;"
offset="1"
id="stopWhiteTransparent" />
</linearGradient>
<linearGradient
inkscape:collect="always"
xlink:href="#WhiteTransparent"
id="linearGradient10409"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(3.180358,0.000000,0.000000,0.346182,-3.048520,-4.711982)"
x1="26.845953"
y1="160.47531"
x2="26.888615"
y2="207.16502" />
<linearGradient
inkscape:collect="always"
xlink:href="#Basic3DDarkGradient"
id="linearGradient10415"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(1.531530,0.000000,0.000000,0.718878,-3.048520,-5.175702)"
x1="3.3979435"
y1="124.18470"
x2="78.711426"
y2="124.18470" />
<linearGradient
inkscape:collect="always"
xlink:href="#Basic3DDarkGradient"
id="linearGradient10421"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(1.118869,0.000000,0.000000,0.869035,1.624231,-1.421085e-14)"
x1="64.216156"
y1="58.259041"
x2="65.807091"
y2="23.747826" />
<linearGradient
inkscape:collect="always"
xlink:href="#WhiteTransparent"
id="linearGradient194"
gradientTransform="matrix(1.912425,0.000000,0.000000,0.575700,-3.048520,-5.175702)"
x1="38.306545"
y1="235.00525"
x2="41.340191"
y2="148.93845"
gradientUnits="userSpaceOnUse" />
<linearGradient
inkscape:collect="always"
xlink:href="#3DShadowGradient"
id="linearGradient198"
gradientTransform="matrix(1.222691,0.000000,0.000000,0.900458,-3.048520,-5.175702)"
x1="51.691013"
y1="-6.4641781"
x2="59.674019"
y2="52.618374"
gradientUnits="userSpaceOnUse" />
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient92"
id="linearGradient225"
gradientTransform="scale(1.884921,0.530526)"
x1="34.063450"
y1="113.74319"
x2="34.190170"
y2="85.134789"
gradientUnits="userSpaceOnUse" />
<linearGradient
inkscape:collect="always"
xlink:href="#Basic3DDarkGradient"
id="linearGradient102"
gradientUnits="userSpaceOnUse"
gradientTransform="scale(1.459604,0.685117)"
x1="55.407467"
y1="92.169785"
x2="55.407467"
y2="253.63820" />
<linearGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="linearGradient866"
gradientUnits="userSpaceOnUse"
gradientTransform="scale(1.822611,0.548663)"
x1="38.521580"
y1="237.15240"
x2="33.548130"
y2="125.36791" />
</defs>
<path
sodipodi:type="arc"
style="fill:url(#radialGradient2970);fill-opacity:1.0000000;fill-rule:evenodd;stroke-width:1.0000000pt"
id="path10398"
sodipodi:cx="25.912205"
sodipodi:cy="175.83524"
sodipodi:rx="56.143108"
sodipodi:ry="56.143108"
d="M 82.055313 175.83524 A 56.143108 56.143108 0 1 1 -30.230904,175.83524 A 56.143108 56.143108 0 1 1 82.055313 175.83524 z"
transform="matrix(1.061544,0.000000,0.000000,7.393471e-2,34.34913,106.7019)" />
<path
style="fill:#ffcb00;fill-opacity:1.0000000;fill-rule:evenodd;stroke:#000000;stroke-width:3.8750000;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000;stroke-dasharray:none;"
d="M 13.527831,89.021069 L 13.527831,23.621047 C 13.527831,17.011674 16.786355,12.239726 23.632986,12.239726 L 57.099549,12.239726 C 63.946187,12.239726 64.776825,23.403470 71.623463,23.403470 L 109.74872,23.403470 C 112.83991,23.403470 115.19518,26.600999 115.19518,30.275073 L 115.19518,89.021069 L 13.527831,89.021069 z "
id="path10399"
sodipodi:nodetypes="cczzzzzcc" />
<path
style="fill:url(#linearGradient198);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.2500000;stroke-opacity:0.33962265"
d="M 17.314787,85.634649 L 17.314787,26.447289 C 17.314787,20.465772 20.263779,16.147135 26.460007,16.147135 L 54.923970,16.147135 C 61.120207,16.147135 61.871939,26.250381 68.068184,26.250381 L 106.73964,26.250381 C 109.53718,26.250381 111.66872,29.144162 111.66872,32.469216 L 111.66872,85.634649 L 17.314787,85.634649 z "
id="path10401"
sodipodi:nodetypes="cczzzzzcc" />
<path
style="fill:url(#linearGradient10421);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.2500000;stroke-opacity:1.0000000"
d="M 14.777831,89.021070 L 14.777831,23.621047 C 14.777831,17.011674 17.946212,12.239726 24.603439,12.239726 L 57.144192,12.239726 C 63.801426,12.239726 64.609086,23.403470 71.266320,23.403470 L 108.33689,23.403470 C 111.34257,23.403470 113.63268,26.600999 113.63268,30.275073 L 113.63268,89.021070 L 14.777831,89.021070 z "
id="path10400"
sodipodi:nodetypes="cczzzzzcc" />
<path
style="fill:#fafafa;fill-opacity:1.0000000;fill-rule:evenodd;stroke:#000000;stroke-width:1.9673948;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:0.58823532"
d="M 29.832632,32.680251 L 29.832632,109.26545 L 98.692404,109.26545 L 98.717504,32.745896 L 29.832632,32.680251 z "
id="path10402"
sodipodi:nodetypes="ccccc" />
<path
style="fill:url(#linearGradient225);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.4895619;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:0.58823532"
d="M 28.940122,37.015430 L 28.940122,56.689800 L 98.816229,56.689800 L 98.841698,37.032293 L 28.940122,37.015430 z "
id="path10424"
sodipodi:nodetypes="ccccc" />
<path
style="fill:#ffc300;fill-opacity:1.0000000;fill-rule:evenodd;stroke:#000000;stroke-width:5.0000000;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000;stroke-dasharray:none;"
d="M 3.5800406,67.752282 L 9.3924860,108.43403 C 9.9148550,112.09013 13.522236,116.26770 17.204085,116.26770 L 112.43256,116.26770 C 115.68675,116.26770 117.80666,111.66197 118.29127,108.43403 L 124.39889,67.752282 C 125.47737,60.568651 121.61305,53.386027 115.81257,53.386027 L 12.166386,53.386027 C 6.3658748,53.386027 2.5527687,60.562327 3.5800406,67.752282 z "
id="path10403"
sodipodi:nodetypes="czzzzzzzz" />
<path
style="opacity:0.28301886;fill:url(#linearGradient10415);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.3937240;stroke-miterlimit:4.0000000;stroke-opacity:0.31372550"
d="M 4.3152919,67.077140 L 10.532030,107.87857 C 11.029756,111.14522 14.611954,114.82222 18.248618,114.87654 L 111.38570,116.26770 C 114.59996,116.31572 116.73226,112.16028 117.17316,109.26973 L 123.66456,66.711464 C 124.64574,60.278708 120.91259,53.857352 115.18267,53.877816 L 12.797190,54.243492 C 7.0672744,54.263957 3.3364850,60.653076 4.3152919,67.077140 z "
id="path10404"
sodipodi:nodetypes="czzzzzzzz" />
<path
style="opacity:0.48427674;fill:url(#linearGradient102);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.3937240;stroke-miterlimit:4.0000000;stroke-opacity:0.48026314"
d="M 4.3152920,67.077140 L 9.6481460,109.20440 C 10.063130,112.48258 13.727666,116.19984 17.364735,116.20237 L 111.38570,116.26770 C 114.60032,116.26993 116.73226,112.16028 117.17316,109.26973 L 123.66456,66.711464 C 124.64574,60.278708 120.91259,53.857352 115.18267,53.877816 L 12.797190,54.243492 C 7.0672740,54.263957 3.4992020,60.630384 4.3152920,67.077140 z "
id="path101"
sodipodi:nodetypes="czzzzzzzz" />
<path
style="opacity:0.11320753;fill:url(#linearGradient194);fill-opacity:1.0000000;fill-rule:evenodd;stroke-width:1.0000000pt"
d="M 10.033008,78.399512 L 14.020810,101.48840 C 14.701688,105.43060 14.205694,111.19236 19.940778,111.16118 L 106.40045,110.69105 C 113.40458,110.65296 112.79439,107.21951 113.80744,102.42459 L 118.86488,78.486788 L 10.033008,78.399512 z "
id="path10405"
sodipodi:nodetypes="czzzzcc" />
<path
style="fill:url(#linearGradient10409);fill-opacity:1.0000000;fill-rule:evenodd;stroke-width:0.90415878pt"
d="M 4.9682151,66.485404 C 4.7818079,67.291978 8.2654741,59.375578 14.171745,59.375578 L 111.83689,59.375578 C 119.10273,59.375578 122.28228,66.950432 122.46870,66.143857 C 122.65511,65.337290 124.48911,54.536131 113.18243,54.536131 L 14.596023,54.536131 C 3.1496173,54.536131 5.1546221,65.678836 4.9682151,66.485404 z "
id="path10407"
sodipodi:nodetypes="czzzzzz" />
<path
style="fill:none;fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:2.6231930;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
d="M 3.5800406,67.752282 L 9.3924860,108.43403 C 9.9148550,112.09013 13.522236,116.26770 17.204085,116.26770 L 112.43256,116.26770 C 115.68675,116.26770 117.80666,111.66197 118.29127,108.43403 L 124.39889,67.752282 C 125.47737,60.568651 121.61305,53.386027 115.81257,53.386027 L 12.166386,53.386027 C 6.3658748,53.386027 2.5527687,60.562327 3.5800406,67.752282 z "
id="path99"
sodipodi:nodetypes="czzzzzzzz" />
<path
style="fill:url(#linearGradient866);fill-opacity:1.0;fill-rule:evenodd;stroke-width:1.0000000pt"
d="M 8.8007750,67.899512 L 14.020810,101.48840 C 19.052329,79.460767 108.36546,78.976869 113.80744,102.42459 L 118.86488,67.986788 L 8.8007750,67.899512 z "
id="path864"
sodipodi:nodetypes="ccccc" />
</svg>

After

Width:  |  Height:  |  Size: 15 KiB

View File

@@ -0,0 +1,350 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<!--
Created By Andrew Fitzsimon.
Much of this document has been manually cleaned and crafted in a text editor so that only the colour definitions and basic presentation related data remain in the XML.
Changes to this document may compromise the structure of this palette.
-->
<svg
version="1.0"
x="00"
y="00"
width="128"
height="128"
id="Etiquette"
sodipodi:version="0.32"
inkscape:version="0.40"
sodipodi:docname="stock_home.svg"
sodipodi:docbase="/usr/share/icons/dlg-etiquette/scalable/stock"
xmlns="http://www.w3.org/2000/svg"
xmlns:cc="http://web.resource.org/cc/"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:xlink="http://www.w3.org/1999/xlink">
<metadata
id="About">
<rdf:RDF
id="RDF232">
<cc:Work
rdf:about=""
id="Work233">
<dc:format
id="format234">image/svg+xml</dc:format>
<dc:type
id="type236"
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:creator
id="creator1291">
<cc:Agent
id="Agent1292">
<dc:title
id="title1293">Andrew Fitzsimon</dc:title>
</cc:Agent>
</dc:creator>
<dc:date
id="date1295">2004-12-25</dc:date>
<dc:title
id="title1297">Etiquette Icon</dc:title>
<cc:license
id="license1299"
rdf:resource="http://creativecommons.org/licenses/by/2.0/" />
<dc:rights
id="rights1308">
<cc:Agent
id="Agent1309">
<dc:title
id="title1310">Andrew Fitzsimon</dc:title>
</cc:Agent>
</dc:rights>
</cc:Work>
<cc:License
rdf:about="http://creativecommons.org/licenses/by/2.0/"
id="License1300">
<cc:permits
rdf:resource="http://web.resource.org/cc/Reproduction"
id="permits1301" />
<cc:permits
rdf:resource="http://web.resource.org/cc/Distribution"
id="permits1302" />
<cc:requires
rdf:resource="http://web.resource.org/cc/Notice"
id="requires1303" />
<cc:requires
rdf:resource="http://web.resource.org/cc/Attribution"
id="requires1304" />
<cc:prohibits
rdf:resource="http://web.resource.org/cc/CommercialUse"
id="prohibits1305" />
<cc:permits
rdf:resource="http://web.resource.org/cc/DerivativeWorks"
id="permits1306" />
<cc:requires
rdf:resource="http://web.resource.org/cc/ShareAlike"
id="requires1307" />
</cc:License>
</rdf:RDF>
</metadata>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="0"
inkscape:zoom="3.2403846"
inkscape:cx="55.293473"
inkscape:cy="53.251675"
inkscape:window-width="769"
inkscape:window-height="853"
inkscape:window-x="163"
inkscape:window-y="26"
inkscape:current-layer="Etiquette"
showgrid="true"
gridspacingx="8.0000000pt"
gridspacingy="8.0000000pt"
gridoriginy="0.0000000pt"
gridoriginx="0pt"
inkscape:grid-points="false"
gridtolerance="40pt"
showborder="true"
inkscape:grid-bbox="false"
gridcolor="#ffffff"
gridopacity="0.0000000"
gridempspacing="14"
gridempcolor="#3f3fff"
gridempopacity="0.0000000"
showguides="true"
inkscape:guide-bbox="true" />
<defs
id="Gradients">
<linearGradient
inkscape:collect="always"
id="linearGradient92">
<stop
style="stop-color:#000000;stop-opacity:1;"
offset="0"
id="stop93" />
<stop
style="stop-color:#000000;stop-opacity:0;"
offset="1"
id="stop94" />
</linearGradient>
<linearGradient
id="3DShadowGradient">
<stop
style="stop-color:#565248;stop-opacity:0.50000000;"
offset="0.0000000"
id="stop3933" />
<stop
style="stop-color:#565248;stop-opacity:0;"
offset="1"
id="stop3934" />
</linearGradient>
<radialGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="radialGradient2970"
gradientUnits="userSpaceOnUse"
cx="25.912205"
cy="175.83524"
fx="25.459438"
fy="142.80988"
r="56.143108" />
<linearGradient
id="Basic3DDarkGradient">
<stop
style="stop-color:#fff9e7;stop-opacity:0.77966100;"
offset="0.0000000"
id="stop3929" />
<stop
style="stop-color:#807d74;stop-opacity:0;"
offset="1"
id="stop3930" />
</linearGradient>
<linearGradient
id="MaterialSoftShadow">
<stop
style="stop-color:#000000;stop-opacity:0.215;"
offset="0"
id="stop2619" />
<stop
style="stop-color:#000000;stop-opacity:0.098;"
offset="0.50000000"
id="stop2621" />
<stop
style="stop-color:#000000;stop-opacity:0;"
offset="1"
id="stop2620" />
</linearGradient>
<linearGradient
id="WhiteTransparent">
<stop
style="stop-color:#ffffff;stop-opacity:1;"
offset="0"
id="stopWhiteFull" />
<stop
style="stop-color:#ffffff;stop-opacity:0;"
offset="1"
id="stopWhiteTransparent" />
</linearGradient>
<linearGradient
inkscape:collect="always"
xlink:href="#WhiteTransparent"
id="linearGradient10409"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(3.180358,0.000000,0.000000,0.346182,-3.048520,-4.711982)"
x1="26.845953"
y1="160.47531"
x2="26.888615"
y2="207.16502" />
<linearGradient
inkscape:collect="always"
xlink:href="#Basic3DDarkGradient"
id="linearGradient10415"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(1.531530,0.000000,0.000000,0.718878,-3.048520,-5.175702)"
x1="3.3979435"
y1="124.18470"
x2="78.711426"
y2="124.18470" />
<linearGradient
inkscape:collect="always"
xlink:href="#Basic3DDarkGradient"
id="linearGradient10421"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(1.118869,0.000000,0.000000,0.869035,1.624230,-8.526515e-14)"
x1="64.216156"
y1="58.259041"
x2="65.807091"
y2="23.747826" />
<linearGradient
inkscape:collect="always"
xlink:href="#WhiteTransparent"
id="linearGradient194"
gradientTransform="matrix(1.912425,0.000000,0.000000,0.575700,-3.048520,-5.175702)"
x1="38.306545"
y1="235.00525"
x2="41.340191"
y2="148.93845"
gradientUnits="userSpaceOnUse" />
<linearGradient
inkscape:collect="always"
xlink:href="#3DShadowGradient"
id="linearGradient198"
gradientTransform="matrix(1.222691,0.000000,0.000000,0.900458,-3.048520,-5.175702)"
x1="51.691013"
y1="-6.4641781"
x2="59.674019"
y2="52.618374"
gradientUnits="userSpaceOnUse" />
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient92"
id="linearGradient225"
gradientTransform="scale(1.884921,0.530526)"
x1="34.063450"
y1="113.74319"
x2="34.190170"
y2="85.134789"
gradientUnits="userSpaceOnUse" />
<linearGradient
inkscape:collect="always"
xlink:href="#Basic3DDarkGradient"
id="linearGradient102"
gradientUnits="userSpaceOnUse"
gradientTransform="scale(1.459604,0.685117)"
x1="55.407467"
y1="92.169785"
x2="55.407467"
y2="253.63820" />
<linearGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="linearGradient866"
gradientUnits="userSpaceOnUse"
gradientTransform="scale(1.822611,0.548663)"
x1="38.521580"
y1="237.15240"
x2="33.548130"
y2="125.36791" />
</defs>
<path
sodipodi:type="arc"
style="fill:url(#radialGradient2970);fill-opacity:1.0000000;fill-rule:evenodd;stroke-width:1.0000000pt"
id="path10398"
sodipodi:cx="25.912205"
sodipodi:cy="175.83524"
sodipodi:rx="56.143108"
sodipodi:ry="56.143108"
d="M 82.055313 175.83524 A 56.143108 56.143108 0 1 1 -30.230904,175.83524 A 56.143108 56.143108 0 1 1 82.055313 175.83524 z"
transform="matrix(1.061544,0.000000,0.000000,7.393471e-2,34.34913,106.7019)" />
<path
style="fill:#548fcb;fill-opacity:1.0000000;fill-rule:evenodd;stroke:#000000;stroke-width:3.8750000;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000;stroke-dasharray:none;"
d="M 13.527831,89.021069 L 13.527831,23.621047 C 13.527831,17.011674 16.786355,12.239726 23.632986,12.239726 L 57.099549,12.239726 C 63.946187,12.239726 64.776825,23.403470 71.623463,23.403470 L 109.74872,23.403470 C 112.83991,23.403470 115.19518,26.600999 115.19518,30.275073 L 115.19518,89.021069 L 13.527831,89.021069 z "
id="path10399"
sodipodi:nodetypes="cczzzzzcc" />
<path
style="fill:url(#linearGradient198);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.2500000;stroke-opacity:0.33962265"
d="M 17.314787,85.634649 L 17.314787,26.447289 C 17.314787,20.465772 20.263779,16.147135 26.460007,16.147135 L 54.923970,16.147135 C 61.120207,16.147135 61.871939,26.250381 68.068184,26.250381 L 106.73964,26.250381 C 109.53718,26.250381 111.66872,29.144162 111.66872,32.469216 L 111.66872,85.634649 L 17.314787,85.634649 z "
id="path10401"
sodipodi:nodetypes="cczzzzzcc" />
<path
style="fill:url(#linearGradient10421);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.2500000;stroke-opacity:1.0000000"
d="M 14.777831,89.021070 L 14.777831,23.621047 C 14.777831,17.011674 17.946212,12.239726 24.603439,12.239726 L 57.144192,12.239726 C 63.801426,12.239726 64.609086,23.403470 71.266320,23.403470 L 108.33689,23.403470 C 111.34257,23.403470 113.63268,26.600999 113.63268,30.275073 L 113.63268,89.021070 L 14.777831,89.021070 z "
id="path10400"
sodipodi:nodetypes="cczzzzzcc" />
<path
style="fill:#fafafa;fill-opacity:1.0000000;fill-rule:evenodd;stroke:#000000;stroke-width:1.9673948;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:0.58823532"
d="M 29.832632,32.680251 L 29.832632,109.26545 L 98.692404,109.26545 L 98.717504,32.745896 L 29.832632,32.680251 z "
id="path10402"
sodipodi:nodetypes="ccccc" />
<path
style="fill:url(#linearGradient225);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.4895619;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:0.58823532"
d="M 28.940122,37.015430 L 28.940122,56.689800 L 98.816229,56.689800 L 98.841698,37.032293 L 28.940122,37.015430 z "
id="path10424"
sodipodi:nodetypes="ccccc" />
<path
style="fill:#2465ae;fill-opacity:1.0000000;fill-rule:evenodd;stroke:#000000;stroke-width:5.0000000;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000;"
d="M 3.5800410,67.752282 L 9.3924860,108.43403 C 9.9148550,112.09013 13.522236,116.26770 17.204085,116.26770 L 112.43256,116.26770 C 115.68675,116.26770 117.80666,111.66197 118.29127,108.43403 L 124.39889,67.752282 C 125.47737,60.568651 121.61305,53.386027 115.81257,53.386027 L 12.166386,53.386027 C 6.3658750,53.386027 2.5527690,60.562327 3.5800410,67.752282 z "
id="path10403"
sodipodi:nodetypes="czzzzzzzz" />
<path
style="opacity:0.28301886;fill:url(#linearGradient10415);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.3937240;stroke-miterlimit:4.0000000;stroke-opacity:0.31372550"
d="M 4.3152920,67.077140 L 10.532030,107.87857 C 11.029756,111.14522 14.611954,114.82222 18.248618,114.87654 L 111.38570,116.26770 C 114.59996,116.31572 116.73226,112.16028 117.17316,109.26973 L 123.66456,66.711464 C 124.64574,60.278708 120.91259,53.857352 115.18267,53.877816 L 12.797190,54.243492 C 7.0672740,54.263957 3.3364850,60.653076 4.3152920,67.077140 z "
id="path10404"
sodipodi:nodetypes="czzzzzzzz" />
<path
style="fill:#ffffff;fill-opacity:1.0000000;stroke:#000000;stroke-width:3.4297814;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
d="M 65.671772,60.215533 L 36.323756,83.990155 L 45.677705,83.990155 L 48.795689,110.88276 L 82.703755,110.88276 L 85.821739,83.990155 L 95.175688,83.990155 L 65.671772,60.215533 z M 58.890159,90.888693 L 72.609285,90.888693 L 71.175197,110.84379 L 60.564803,110.84379 L 58.890159,90.888693 z "
id="rect1119"
sodipodi:nodetypes="ccccccccccccc" />
<path
style="opacity:0.48427674;fill:url(#linearGradient102);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:1.3937240;stroke-miterlimit:4.0000000;stroke-opacity:0.48026314"
d="M 4.3152920,67.077140 L 9.6481460,109.20440 C 10.063130,112.48258 13.727666,116.19984 17.364735,116.20237 L 111.38570,116.26770 C 114.60032,116.26993 116.73226,112.16028 117.17316,109.26973 L 123.66456,66.711464 C 124.64574,60.278708 120.91259,53.857352 115.18267,53.877816 L 12.797190,54.243492 C 7.0672740,54.263957 3.4992020,60.630384 4.3152920,67.077140 z "
id="path101"
sodipodi:nodetypes="czzzzzzzz" />
<path
style="opacity:0.11320753;fill:url(#linearGradient194);fill-opacity:1.0000000;fill-rule:evenodd;stroke-width:1.0000000pt"
d="M 10.033008,78.399512 L 14.020810,101.48840 C 14.701688,105.43060 14.205694,111.19236 19.940778,111.16118 L 106.40045,110.69105 C 113.40458,110.65296 112.79439,107.21951 113.80744,102.42459 L 118.86488,78.486788 L 10.033008,78.399512 z "
id="path10405"
sodipodi:nodetypes="czzzzcc" />
<path
style="fill:url(#linearGradient10409);fill-opacity:1.0000000;fill-rule:evenodd;stroke-width:0.90415878pt"
d="M 4.9682151,66.485404 C 4.7818079,67.291978 8.2654741,59.375578 14.171745,59.375578 L 111.83689,59.375578 C 119.10273,59.375578 122.28228,66.950432 122.46870,66.143857 C 122.65511,65.337290 124.48911,54.536131 113.18243,54.536131 L 14.596023,54.536131 C 3.1496173,54.536131 5.1546221,65.678836 4.9682151,66.485404 z "
id="path10407"
sodipodi:nodetypes="czzzzzz" />
<path
style="fill:none;fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:2.6231930;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
d="M 3.5800406,67.752282 L 9.3924860,108.43403 C 9.9148550,112.09013 13.522236,116.26770 17.204085,116.26770 L 112.43256,116.26770 C 115.68675,116.26770 117.80666,111.66197 118.29127,108.43403 L 124.39889,67.752282 C 125.47737,60.568651 121.61305,53.386027 115.81257,53.386027 L 12.166386,53.386027 C 6.3658748,53.386027 2.5527687,60.562327 3.5800406,67.752282 z "
id="path99"
sodipodi:nodetypes="czzzzzzzz" />
<path
style="fill:url(#linearGradient866);fill-opacity:1.0000000;fill-rule:evenodd;stroke-width:1.0000000pt"
d="M 8.8007750,67.899512 L 14.020810,101.48840 C 19.052329,79.460767 108.36546,78.976869 113.80744,102.42459 L 118.86488,67.986788 L 8.8007750,67.899512 z "
id="path864"
sodipodi:nodetypes="ccccc" />
</svg>

After

Width:  |  Height:  |  Size: 15 KiB

View File

@@ -0,0 +1,260 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<!--
Created By Andrew Fitzsimon.
Much of this document has been manually cleaned and crafted in a text editor so that only the colour definitions and basic presentation related data remain in the XML.
Changes to this document may compromise the structure of this palette.
-->
<svg
version="1.0"
x="00"
y="00"
width="128"
height="128"
id="Etiquette"
sodipodi:version="0.32"
inkscape:version="0.40"
sodipodi:docname="gnome-fs-iregular.svg"
sodipodi:docbase="/usr/share/icons/etiqueta/scalable/filesystems"
xmlns="http://www.w3.org/2000/svg"
xmlns:cc="http://web.resource.org/cc/"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:xlink="http://www.w3.org/1999/xlink">
<metadata
id="About">
<rdf:RDF
id="RDF232">
<cc:Work
rdf:about=""
id="Work233">
<dc:format
id="format234">image/svg+xml</dc:format>
<dc:type
id="type236"
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:creator
id="creator1291">
<cc:Agent
id="Agent1292">
<dc:title
id="title1293">Andrew Fitzsimon</dc:title>
</cc:Agent>
</dc:creator>
<dc:date
id="date1295">2004-12-25</dc:date>
<dc:title
id="title1297">Etiquette Icon</dc:title>
<cc:license
id="license1299"
rdf:resource="http://creativecommons.org/licenses/by/2.0/" />
<dc:rights
id="rights1308">
<cc:Agent
id="Agent1309">
<dc:title
id="title1310">Andrew Fitzsimon</dc:title>
</cc:Agent>
</dc:rights>
</cc:Work>
<cc:License
rdf:about="http://creativecommons.org/licenses/by/2.0/"
id="License1300">
<cc:permits
rdf:resource="http://web.resource.org/cc/Reproduction"
id="permits1301" />
<cc:permits
rdf:resource="http://web.resource.org/cc/Distribution"
id="permits1302" />
<cc:requires
rdf:resource="http://web.resource.org/cc/Notice"
id="requires1303" />
<cc:requires
rdf:resource="http://web.resource.org/cc/Attribution"
id="requires1304" />
<cc:prohibits
rdf:resource="http://web.resource.org/cc/CommercialUse"
id="prohibits1305" />
<cc:permits
rdf:resource="http://web.resource.org/cc/DerivativeWorks"
id="permits1306" />
<cc:requires
rdf:resource="http://web.resource.org/cc/ShareAlike"
id="requires1307" />
</cc:License>
</rdf:RDF>
</metadata>
<sodipodi:namedview
id="base"
pagecolor="#f8f8f8"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0000000"
inkscape:pageshadow="0"
inkscape:zoom="1.4142136"
inkscape:cx="36.113222"
inkscape:cy="28.731500"
inkscape:window-width="554"
inkscape:window-height="579"
inkscape:window-x="46"
inkscape:window-y="26"
inkscape:current-layer="Etiquette"
showgrid="true"
gridspacingx="4.0000000pt"
gridspacingy="4.0000000pt"
gridoriginy="0.0000000pt"
gridoriginx="0pt"
inkscape:grid-points="true"
gridtolerance="40pt"
showborder="true"
inkscape:grid-bbox="false"
gridcolor="#3f3fff"
gridopacity="0.082352941"
gridempspacing="2"
gridempcolor="#3f3fff"
gridempopacity="0.082352941" />
<defs
id="Gradients">
<linearGradient
inkscape:collect="always"
id="linearGradient486">
<stop
style="stop-color:#000000;stop-opacity:1;"
offset="0"
id="stop487" />
<stop
style="stop-color:#000000;stop-opacity:0;"
offset="1"
id="stop488" />
</linearGradient>
<linearGradient
id="MaterialSoftShadow">
<stop
style="stop-color:#000000;stop-opacity:0.215;"
offset="0"
id="stop2619" />
<stop
style="stop-color:#000000;stop-opacity:0.098;"
offset="0.50000000"
id="stop2621" />
<stop
style="stop-color:#000000;stop-opacity:0;"
offset="1"
id="stop2620" />
</linearGradient>
<linearGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="linearGradient437"
gradientTransform="matrix(0.919623,0.000000,0.000000,0.996992,2.812673,5.122013)"
x1="118.16164"
y1="11.005426"
x2="74.861580"
y2="51.599213"
gradientUnits="userSpaceOnUse" />
<linearGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="linearGradient439"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(0.918021,0.000000,0.000000,0.998732,2.812673,5.122013)"
x1="-59.549145"
y1="197.54245"
x2="76.516380"
y2="66.194740" />
<linearGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="linearGradient443"
x1="106.87500"
y1="17.296875"
x2="101.95312"
y2="22.218750"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(0.955728,0.000000,0.000000,0.959329,2.812673,5.122013)" />
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient486"
id="linearGradient489"
gradientTransform="matrix(0.919623,0.000000,0.000000,0.996992,2.812673,5.122013)"
x1="-216.37779"
y1="241.99133"
x2="123.05903"
y2="3.9652903"
gradientUnits="userSpaceOnUse" />
<linearGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="linearGradient131"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(-0.142813,0.534996,1.598964,0.430056,107.5728,-46.45381)"
x1="138.56406"
y1="10.392305"
x2="155.88457"
y2="10.392305" />
<linearGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="linearGradient132"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(-0.532987,0.143352,-0.428441,-1.604989,171.7494,17.96460)"
x1="138.56406"
y1="10.392305"
x2="155.88457"
y2="10.392305" />
<linearGradient
inkscape:collect="always"
xlink:href="#MaterialSoftShadow"
id="linearGradient1723"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(0.919623,0.000000,0.000000,0.996992,2.812673,5.122013)"
x1="118.16164"
y1="11.005426"
x2="74.861580"
y2="51.599213" />
</defs>
<path
style="fill:url(#linearGradient437);fill-opacity:1.0000000;fill-rule:evenodd;stroke:url(#linearGradient489);stroke-width:2.3938165;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
d="M 12.369950,8.0000000 L 12.369950,123.11947 L 118.55594,123.11947 L 117.50000,36.779868 L 88.828168,8.0000000 L 12.369950,8.0000000 z "
id="path433"
sodipodi:nodetypes="cccccc" />
<path
style="fill:#f6f6f6;fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:2.5000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
d="M 12.369950,8.0000000 L 12.369950,123.11947 L 118.55594,123.11947 L 117.50000,36.779868 L 88.828168,8.0000000 L 12.369950,8.0000000 z "
id="path6763"
sodipodi:nodetypes="cccccc" />
<path
style="fill:url(#linearGradient439);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:2.5000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
d="M 12.369950,12.796645 L 12.369950,123.11947 L 113.77730,123.11947 L 112.76888,40.377351 L 85.387354,12.796645 L 12.369950,12.796645 z "
id="path438"
sodipodi:nodetypes="cccccc" />
<path
style="fill:url(#linearGradient1723);fill-opacity:1.0000000;fill-rule:evenodd;stroke:#000000;stroke-width:4.2500000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000;stroke-dasharray:none;"
d="M 12.369950,8.0000000 L 12.369950,123.11947 L 118.55594,123.11947 L 117.50000,36.779868 L 88.828168,8.0000000 L 12.369950,8.0000000 z "
id="path1"
sodipodi:nodetypes="cccccc" />
<path
style="fill:#f6f6f6;fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:2.5000000;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
d="M 88.828168,8.0000000 L 88.828168,36.779868 L 117.50000,36.779868 L 88.828168,8.0000000 z "
id="path6764"
sodipodi:nodetypes="cccc" />
<path
style="fill:url(#linearGradient443);fill-opacity:1.0000000;fill-rule:evenodd;stroke:#000000;stroke-width:1.6250000;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000;stroke-dasharray:none;"
d="M 88.828168,8.0000000 L 88.828168,36.779868 L 117.50000,36.779868 L 88.828168,8.0000000 z "
id="path6770"
sodipodi:nodetypes="cccc" />
<path
style="fill:url(#linearGradient132);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:0.25000000pt;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1.0000000"
d="M 88.828168,8.0000000 L 79.270891,8.0000000 L 88.828168,36.779868 L 88.828168,8.0000000 z "
id="path11"
sodipodi:nodetypes="cccc" />
<path
style="fill:url(#linearGradient131);fill-opacity:1.0000000;fill-rule:evenodd;stroke:none;stroke-width:0.25000000pt;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1.0000000"
d="M 117.50000,36.779868 L 117.50000,46.373157 L 88.828168,36.779868 L 117.50000,36.779868 z "
id="path105"
sodipodi:nodetypes="cccc" />
</svg>

After

Width:  |  Height:  |  Size: 10 KiB

View File

@@ -0,0 +1,306 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:ns="http://creativecommons.org/ns#"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://web.resource.org/cc/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
inkscape:export-ydpi="90.000000"
inkscape:export-xdpi="90.000000"
inkscape:export-filename="/home/jimmac/src/cvs/gnome/gnome-icon-theme/32x32/emblems/emblem-symbolic-link.png"
width="48"
height="48"
id="svg11300"
sodipodi:version="0.32"
inkscape:version="0.45"
sodipodi:docbase="/home/dobey/Projects/gnome-icon-theme/scalable/emblems"
sodipodi:docname="emblem-symbolic-link.svg"
version="1.0"
inkscape:output_extension="org.inkscape.output.svg.inkscape">
<defs
id="defs3">
<linearGradient
inkscape:collect="always"
id="linearGradient5282">
<stop
style="stop-color:#888a85;stop-opacity:1;"
offset="0"
id="stop5284" />
<stop
style="stop-color:#555753;stop-opacity:1"
offset="1"
id="stop5286" />
</linearGradient>
<linearGradient
inkscape:collect="always"
id="linearGradient5403">
<stop
style="stop-color:#000000;stop-opacity:1;"
offset="0"
id="stop5405" />
<stop
style="stop-color:#000000;stop-opacity:0;"
offset="1"
id="stop5407" />
</linearGradient>
<linearGradient
inkscape:collect="always"
id="linearGradient5393">
<stop
style="stop-color:#ffffff;stop-opacity:1;"
offset="0"
id="stop5395" />
<stop
style="stop-color:#ffffff;stop-opacity:0;"
offset="1"
id="stop5397" />
</linearGradient>
<linearGradient
id="linearGradient5265">
<stop
style="stop-color:#ffffff;stop-opacity:1;"
offset="0"
id="stop5267" />
<stop
id="stop5281"
offset="0.28349411"
style="stop-color:#ffffff;stop-opacity:1;" />
<stop
style="stop-color:#ffffff;stop-opacity:0;"
offset="1"
id="stop5269" />
</linearGradient>
<linearGradient
inkscape:collect="always"
id="linearGradient2782">
<stop
style="stop-color:black;stop-opacity:1;"
offset="0"
id="stop2784" />
<stop
style="stop-color:black;stop-opacity:0;"
offset="1"
id="stop2786" />
</linearGradient>
<radialGradient
inkscape:collect="always"
xlink:href="#linearGradient2782"
id="radialGradient2788"
cx="28.682018"
cy="39.779884"
fx="28.682018"
fy="39.779884"
r="12.59534"
gradientTransform="matrix(1,0,0,0.329825,0,26.6595)"
gradientUnits="userSpaceOnUse" />
<radialGradient
inkscape:collect="always"
xlink:href="#linearGradient5265"
id="radialGradient5271"
cx="16.350952"
cy="12.578328"
fx="16.350952"
fy="12.578328"
r="6.9271288"
gradientTransform="matrix(3.5838969,0,0,3.0076999,-41.766746,-27.550587)"
gradientUnits="userSpaceOnUse" />
<radialGradient
inkscape:collect="always"
xlink:href="#linearGradient2782"
id="radialGradient5285"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(1,0,0,0.329825,0,26.6595)"
cx="28.682018"
cy="39.779884"
fx="28.682018"
fy="39.779884"
r="12.59534" />
<filter
inkscape:collect="always"
id="filter5379"
x="-0.14493342"
width="1.2898668"
y="-0.43942577"
height="1.8788517">
<feGaussianBlur
inkscape:collect="always"
stdDeviation="1.521238"
id="feGaussianBlur5381" />
</filter>
<radialGradient
inkscape:collect="always"
xlink:href="#linearGradient5393"
id="radialGradient5399"
cx="12.893971"
cy="13.137217"
fx="12.893971"
fy="13.137217"
r="6.9404535"
gradientTransform="matrix(0.9391513,0.9314688,-2.7714066,2.7714066,47.469422,-33.517793)"
gradientUnits="userSpaceOnUse" />
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient5403"
id="linearGradient5409"
x1="33.688488"
y1="39.894127"
x2="26.822592"
y2="32.924358"
gradientUnits="userSpaceOnUse" />
<filter
inkscape:collect="always"
id="filter5471"
x="-0.13357687"
width="1.2671537"
y="-0.075597449"
height="1.1511949">
<feGaussianBlur
inkscape:collect="always"
stdDeviation="1.2011151"
id="feGaussianBlur5473" />
</filter>
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient5282"
id="linearGradient5288"
x1="18.666454"
y1="23.601217"
x2="19.550337"
y2="43.589653"
gradientUnits="userSpaceOnUse" />
</defs>
<sodipodi:namedview
stroke="#ef2929"
fill="#888a85"
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="0.25490196"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="1"
inkscape:cx="43.421283"
inkscape:cy="15.209517"
inkscape:current-layer="layer1"
showgrid="true"
inkscape:grid-bbox="true"
inkscape:document-units="px"
inkscape:showpageshadow="false"
inkscape:window-width="908"
inkscape:window-height="924"
inkscape:window-x="587"
inkscape:window-y="159"
width="48px"
height="48px">
<inkscape:grid
type="xygrid"
id="grid4684" />
</sodipodi:namedview>
<metadata
id="metadata4">
<rdf:RDF>
<ns:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:creator>
<ns:Agent>
<dc:title>Jakub Steiner</dc:title>
</ns:Agent>
</dc:creator>
<dc:source>http://jimmac.musichall.cz</dc:source>
<ns:license
rdf:resource="http://creativecommons.org/licenses/GPL/2.0/" />
<dc:title>Symbolic Link</dc:title>
<dc:subject>
<rdf:Bag>
<rdf:li>emblem</rdf:li>
<rdf:li>symbolic</rdf:li>
<rdf:li>link</rdf:li>
<rdf:li>pointer</rdf:li>
<rdf:li>io</rdf:li>
<rdf:li>file</rdf:li>
</rdf:Bag>
</dc:subject>
</ns:Work>
<ns:License
rdf:about="http://creativecommons.org/licenses/GPL/2.0/">
<ns:permits
rdf:resource="http://web.resource.org/cc/Reproduction" />
<ns:permits
rdf:resource="http://web.resource.org/cc/Distribution" />
<ns:requires
rdf:resource="http://web.resource.org/cc/Notice" />
<ns:permits
rdf:resource="http://web.resource.org/cc/DerivativeWorks" />
<ns:requires
rdf:resource="http://web.resource.org/cc/ShareAlike" />
<ns:requires
rdf:resource="http://web.resource.org/cc/SourceCode" />
</ns:License>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
id="layer1"
inkscape:label="Layer 1"
inkscape:groupmode="layer">
<path
transform="matrix(0.7315426,0,0,0.8758998,-2.6289879,8.6451927)"
d="M 41.277358,39.779884 A 12.59534,4.1542525 0 1 1 16.086679,39.779884 A 12.59534,4.1542525 0 1 1 41.277358,39.779884 z"
sodipodi:ry="4.1542525"
sodipodi:rx="12.59534"
sodipodi:cy="39.779884"
sodipodi:cx="28.682018"
id="path5283"
style="opacity:0.53012049;color:#000000;fill:url(#radialGradient5285);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;filter:url(#filter5379)"
sodipodi:type="arc" />
<path
sodipodi:type="arc"
style="opacity:0.13402064;color:#000000;fill:url(#radialGradient2788);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
id="path2780"
sodipodi:cx="28.682018"
sodipodi:cy="39.779884"
sodipodi:rx="12.59534"
sodipodi:ry="4.1542525"
d="M 41.277358,39.779884 A 12.59534,4.1542525 0 1 1 16.086679,39.779884 A 12.59534,4.1542525 0 1 1 41.277358,39.779884 z"
transform="matrix(1.2334109,0,0,1.0076725,-8.228868,3.4032918)" />
<path
sodipodi:nodetypes="ccccccsc"
id="path2177"
d="M 13.231032,44.801742 C 32.533918,45.05839 43.631188,27.964269 28.215997,12.281453 L 35.667346,4.5752233 C 35.667346,4.5752233 12.441112,4.5444975 12.441112,4.5444975 L 12.475636,27.974137 C 12.475636,27.974137 20.091254,20.381589 20.091254,20.381589 C 32.630921,32.309936 23.822736,41.798009 12.65267,41.733566 C 11.574838,41.727348 11.093318,44.898513 13.231032,44.801742 z"
style="opacity:1;color:#000000;fill:#e0e3dd;fill-opacity:1;fill-rule:nonzero;stroke:url(#linearGradient5288);stroke-width:0.99999945999999995;stroke-linecap:butt;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:10;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:block;overflow:visible" />
<path
sodipodi:type="inkscape:offset"
inkscape:radius="-0.99764425"
inkscape:original="M 12.4375 4.53125 L 12.46875 27.96875 C 12.46875 27.968751 20.09375 20.375 20.09375 20.375 C 32.633418 32.303346 23.826316 41.783193 12.65625 41.71875 C 11.578418 41.712532 11.081036 44.909271 13.21875 44.8125 C 32.521636 45.069147 43.633941 27.964066 28.21875 12.28125 L 35.65625 4.5625 C 35.656249 4.5624999 12.4375 4.53125 12.4375 4.53125 z "
xlink:href="#path2177"
style="opacity:1;color:#000000;fill:none;fill-opacity:1;fill-rule:nonzero;stroke:url(#radialGradient5271);stroke-width:0.99999946;stroke-linecap:butt;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:10;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:block;overflow:visible"
id="path4686"
inkscape:href="#path2177"
d="M 13.4375,4.53125 L 13.46875,24.53125 C 15.532978,22.475482 19.375,18.65625 19.375,18.65625 C 19.764091,18.269778 20.392159,18.269778 20.78125,18.65625 C 24.006233,21.724012 25.921664,24.684645 26.75,27.46875 C 27.578336,30.252855 27.289756,32.849209 26.15625,35 C 23.918527,39.246006 18.654595,41.65794 12.875,41.6875 C 12.812312,41.800593 12.71644,42.058107 12.71875,42.28125 C 12.72106,42.504393 12.799338,42.665191 12.84375,42.71875 C 12.888162,42.772309 12.89921,42.82555 13.1875,42.8125 C 13.197916,42.812337 13.208334,42.812337 13.21875,42.8125 C 22.573042,42.936873 29.790323,38.866695 32.84375,33.0625 C 35.897177,27.258305 34.996477,19.595374 27.5,11.96875 C 27.133774,11.583574 27.133774,10.978926 27.5,10.59375 L 33.3125,4.5625 C 29.70508,4.5576448 15.075744,4.5334549 13.4375,4.53125 z" />
<path
style="opacity:1;color:#000000;fill:url(#radialGradient5399);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.99999945999999995;stroke-linecap:butt;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:10;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:block;overflow:visible"
d="M 17.159788,43.640829 C 31.514886,43.674319 42.886524,25.842847 27.112134,12.35651 L 33.703778,5.5393836 C 33.703778,5.5393836 13.157265,5.5122029 13.157265,5.5122029 L 13.187806,26.238664 C 13.187806,26.238664 19.924782,19.522105 19.924782,19.522105 C 31.017682,30.074216 27.6074,39.201992 17.814178,41.894344 C 16.994481,42.119695 15.26871,43.726433 17.159788,43.640829 z"
id="path5383"
sodipodi:nodetypes="ccccccsc" />
<path
sodipodi:nodetypes="ccccccsc"
id="path5401"
d="M 17.159788,43.640829 C 31.514886,43.674319 42.886524,25.842847 27.112134,12.35651 L 33.703778,5.5393836 C 33.703778,5.5393836 13.157265,5.5122029 13.157265,5.5122029 L 13.187806,26.238664 C 13.187806,26.238664 19.924782,19.522105 19.924782,19.522105 C 31.017682,30.074216 27.6074,39.201992 17.814178,41.894344 C 16.994481,42.119695 15.26871,43.726433 17.159788,43.640829 z"
style="opacity:0.51204819000000001;color:#000000;fill:url(#linearGradient5409);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.99999945999999995;stroke-linecap:butt;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:10;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:block;overflow:visible;filter:url(#filter5471)" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 13 KiB

View File

@@ -5,7 +5,7 @@ format:
toc: true
toc-depth: 3
code-tools: true
code-fold: true
code-fold: false
---
# Introduction to Unix
@@ -43,6 +43,7 @@ This user information is typically stored in the system's `/etc/passwd` file, a
```{bash}
#| label: passwd
#| eval: false
#| caption: >
#| Sample excerpt from an /etc/passwd file. Each line represents one user account,
#| with fields separated by colons. The fields show, in order: username,
@@ -52,6 +53,26 @@ This user information is typically stored in the system's `/etc/passwd` file, a
cat /etc/passwd | head -15
```
```{bash}
#| echo: false
#| output: asis
echo "root:x:0:0:root:/root:/bin/bash
daemon:x:1:1:daemon:/usr/sbin:/usr/sbin/nologin
bin:x:2:2:bin:/bin:/usr/sbin/nologin
sys:x:3:3:sys:/dev:/usr/sbin/nologin
sync:x:4:65534:sync:/bin:/bin/sync
games:x:5:60:games:/usr/games:/usr/sbin/nologin
man:x:6:12:man:/var/cache/man:/usr/sbin/nologin
lp:x:7:7:lp:/var/spool/lpd:/usr/sbin/nologin
mail:x:8:8:mail:/var/mail:/usr/sbin/nologin
news:x:9:9:news:/var/spool/news:/usr/sbin/nologin
uucp:x:10:10:uucp:/var/spool/uucp:/usr/sbin/nologin
proxy:x:13:13:proxy:/bin:/usr/sbin/nologin
www-data:x:33:33:www-data:/var/www:/usr/sbin/nologin
backup:x:34:34:backup:/var/backups:/usr/sbin/nologin
list:x:38:38:Mailing List Manager:/var/list:/usr/sbin/nologin"
```
## The File System
@@ -63,6 +84,7 @@ In a Unix system, a file name describes a path in a tree. A file name begins wit
```{bash}
#| label: fig-fs-unix
#| eval: false
#| fig-cap: >
#| Example of part of the hierarchy of a Unix file system: The path marked in
#| red corresponds to the filename `/etc/passwd`. This file contains all the
@@ -71,6 +93,30 @@ In a Unix system, a file name describes a path in a tree. A file name begins wit
tree -L 2 /
```
```
/
├── bin -> usr/bin
├── boot
├── dev
├── etc
│ ├── passwd
│ ├── group
│ └── ...
├── home
│ ├── user1
│ └── user2
├── proc
├── root
├── tmp
├── usr
│ ├── bin
│ ├── lib
│ └── ...
└── var
├── log
└── ...
```
This naming system leads to saying that all files in a Unix system are arranged in a tree structure. In this structure, each internal node is designated as a directory, and each leaf of the tree is either a file or an empty directory.
This tree structure contains certain directories that are found in many Unix systems. Among these we can mention:
@@ -97,6 +143,7 @@ The concept of a link (*link* in English) can be assimilated to the concept of a
```{bash}
#| label: fig-fs-link
#| eval: false
#| fig-cap: >
#| `/home/bar/programs` a link to the directory `/usr/bin`:
#| The special file `/home/bar/programs` is a so-called *symbolic*
@@ -106,6 +153,14 @@ The concept of a link (*link* in English) can be assimilated to the concept of a
ls -la /home/bar/
```
```
total 12
drwxr-xr-x 3 bar users 4096 Jan 15 10:30 .
drwxr-xr-x 4 root root 4096 Jan 10 14:22 ..
lrwxrwxrwx 1 bar users 8 Jan 15 10:30 programs -> /usr/bin
-rw-r--r-- 1 bar users 123 Jan 15 10:25 document.txt
```
#### The Directories "." and ".."
{#point-pointpoint}
@@ -113,11 +168,20 @@ The Unix system uses this link system to facilitate the use of the file name tre
```{bash}
#| label: fig-fs-spdir
#| eval: false
#| fig-cap: The links "." and ".." allow moving up the tree.
ls -la
```
```
total 4
drwxr-xr-x 3 user users 4096 Jan 15 10:30 .
drwxr-xr-x 4 user users 4096 Jan 10 14:22 ..
-rw-r--r-- 1 user users 123 Jan 15 10:25 file1.txt
-rw-r--r-- 1 user users 456 Jan 15 10:26 file2.txt
```
These links mean that for each file there is not one name but an infinity of possible names. The file `/home/bar/my_file` can also be named:
- `/home/bar/./my_file`
@@ -176,6 +240,7 @@ To give a concrete aspect to our process, we can consider that it corresponds to
```{bash}
#| label: fig-process-anatomy
#| eval: false
#| fig-cap: >
#| Anatomy of a process: a process can be divided into three main parts
#| that it inherits from its parent.
@@ -183,13 +248,22 @@ To give a concrete aspect to our process, we can consider that it corresponds to
ps aux
```
```
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 1 0.0 0.0 168016 10832 ? Ss Jan15 0:01 /sbin/init
root 2 0.0 0.0 0 0 ? S Jan15 0:00 [kthreadd]
root 3 0.0 0.0 0 0 ? I< Jan15 0:00 [rcu_gp]
user 1234 0.1 0.5 172340 44512 pts/0 Ss 10:30 0:00 bash
user 5678 0.0 0.2 162324 23456 pts/0 R+ 10:31 0:00 ps aux
```
#### The Environment of a Process
A process is an isolated memory area from the rest of the machine in which a program executes. The isolation secures the computer by preventing a program from corrupting the execution of others. Nevertheless, a program must during its execution interact with the rest of the computer, for example to retrieve the data on which it will work and return the results of these calculations.
The environment of a process is dedicated to this interface task between the process and the rest of the system. It contains the description of the system elements that must be known to the process. Roughly, two main types of information are stored in a process's environment: environment variables and streams.
Environment variables make it possible to associate a name with a value describing certain properties of the system. Some of these variables are of very general use, such as `CWD` which contains the "Current Working Directory" used for interpreting relative paths or `PATH` which contains the list of directories where the programs available on the machine are stored. Other variables have a more restricted use, for example `BLASTMAT` and `BLASTDB` are two environment variables used by the `blast` program from NCBI^[http://blast.ncbi.nlm.nih.gov/]. It is possible to obtain the list of environment variables set by the `env` command (page @unix-env). The Unix command to define or modify an environment variable depends on the Unix *shell* you are using. Under `csh` the command is `setenv` (page @unix-setenv).
Environment variables make it possible to associate a name with a value describing certain properties of the system. Some of these variables are of very general use, such as `CWD` which contains the "Current Working Directory" used for interpreting relative paths or `PATH` which contains the list of directories where the programs available on the machine are stored. Other variables have a more restricted use, for example `BLASTMAT` and `BLASTDB` are two environment variables used by the `blast` program from NCBI^[http://blast.ncbi.nlm.nih.gov/]. It is possible to obtain the list of environment variables set by the `env` command (page @unix-env). The Unix command to define or modify an environment variable depends on the Unix *shell* you are using. Under `bash` the command is `export` (page @unix-export).
Streams are virtual pipes through which data flows. A stream operates either in reception or in data transmission. The other end of this pipe is directed either to a file or to another process. Streams, often called "*pipe*" in the Unix world, are the preferred means of data transmission between two processes working together. By default, at least three streams are associated with each process. The standard input stream "*stdin*" through which a Unix program normally receives its data, the standard output stream "*stdout*" which is used by the program to return its results, and the standard error output "*stderr*" used for transmitting error messages and information generated by the program during its execution. The use of these three streams is a Unix convention. A Unix system user therefore expects the program they are using to follow this standard. But it is the responsibility of the program designer to follow it, so some programs do not follow this model, which can sometimes confuse the uninformed user. Whenever a Unix program opens a file to read or write data, it actually modifies its environment by adding a new stream through which it can communicate with the rest of the system.
@@ -217,6 +291,7 @@ Figure @fig-process-life presents graphically the stages of creation and destruc
```{bash}
#| label: fig-process-life
#| eval: false
#| fig-cap: >
#| Life and death of a process: Every process inherits through a more or less
#| long chain of calls to the `fork` system function from the initial process
@@ -233,22 +308,33 @@ Figure @fig-process-life presents graphically the stages of creation and destruc
pstree
```
```
systemd─┬─NetworkManager───2*[{NetworkManager}]
├─accounts-daemon───2*[{accounts-daemon}]
├─avahi-daemon───avahi-daemon
├─bash───pstree
├─cron
├─dbus-daemon
└─2*[systemd───(sd-pam)]
```
The normal chronology to create a new process is to call the `fork` function, to test after this call in which process the program continues its execution. In the child process, you must then call the `exec` function to replace the old program of the new process with the code of the new program to be executed. At the end of this execution, the parent is notified of the end of its child, it definitively releases the process.
## The Shell - A Working Environment
The shell is the most important program for a Unix user. It is through it that they interact with their computer. There is a graphical window system under Unix similar to those encountered under Windows or macOS, it is called XWindows or abbreviated X11. It has the advantage of functioning in client/server mode across the network. This means for a user that their program can run on one machine while they interact with it via their control windows from a second machine. However, we will not talk about this system further in this Unix presentation and we will content ourselves with interacting with our Unix machine in "text" mode via the shell.
The Unix shell^[a shell, i.e., a small protected space in a large Unix machine from which it is possible to work] is a program capable of interpreting a command language. These commands allow the user to launch the execution of a program by specifying to it the data on which it must work, possibly some parameters to adjust its execution, and what should be done with the results. There are many shells. What differentiates them is that their command language is not strictly identical. Two shells are mainly used today: `bash` for "Bourn again shell" which is the modern version of the Bourn shell^[Bash website: http://www.gnu.org/software/bash] (`sh`) and `tcsh` for "Turbo C-Shell" the modern version of the C-Shell^[tcsh website: http://www.tcsh.org/Welcome] (`csh`). Other shells exist such as the Korn shell (`ksh`) developed by David Korn in the early 1980s or the Z-Shell (`zsh`) written by Paul Falstad in 1990 which is another improved version of the Bourn-Shell. Most of these shells allow performing the same operations but sometimes using different syntaxes. Some people prefer one or the other but their reasons are most often subjective. In the rest of this presentation, we will only use `tcsh`. By default on most Unix machines, the two shells: `bash` and `tcsh` are installed. When you connect to a Unix machine, one of the two is launched for you by default. It is possible to change your default shell using the `chsh` command (see page @unix-chsh) or to switch from one shell to another using the commands `bash` (see page @unix-bash) and `tcsh` (see page @unix-tcsh).
The Unix shell^[a shell, i.e., a small protected space in a large Unix machine from which it is possible to work] is a program capable of interpreting a command language. These commands allow the user to launch the execution of a program by specifying to it the data on which it must work, possibly some parameters to adjust its execution, and what should be done with the results. There are many shells. What differentiates them is that their command language is not strictly identical. Two shells are mainly used today: `bash` for "Bourn again shell" which is the modern version of the Bourn shell^[Bash website: http://www.gnu.org/software/bash] (`sh`) and `tcsh` for "Turbo C-Shell" the modern version of the C-Shell^[tcsh website: http://www.tcsh.org/Welcome] (`csh`). Other shells exist such as the Korn shell (`ksh`) developed by David Korn in the early 1980s or the Z-Shell (`zsh`) written by Paul Falstad in 1990 which is another improved version of the Bourn-Shell. Most of these shells allow performing the same operations but sometimes using different syntaxes. Some people prefer one or the other but their reasons are most often subjective. In the rest of this presentation, we will only use `bash`. By default on most Unix machines, the two shells: `bash` and `tcsh` are installed. When you connect to a Unix machine, one of the two is launched for you by default. It is possible to change your default shell using the `chsh` command (see page @unix-chsh) or to switch from one shell to another using the commands `bash` (see page @unix-bash) and `tcsh` (see page @unix-tcsh).
### Basic Structure of a Unix Command
A shell is therefore a program that interprets a computer language that allows easily launching the execution of other programs by indicating to them where to find their data and what to do with the results they produce. This language, like all others, has a vocabulary and a grammar. The languages of the different shells can be considered as dialects of the same language. Also, there are great similarities between them. All the explanations we provide here concern `tcsh` but for the most part, they are applicable to other shells.
A shell is therefore a program that interprets a computer language that allows easily launching the execution of other programs by indicating to them where to find their data and what to do with the results they produce. This language, like all others, has a vocabulary and a grammar. The languages of the different shells can be considered as dialects of the same language. Also, there are great similarities between them. All the explanations we provide here concern `bash` but for the most part, they are applicable to other shells.
The language of a shell mainly defines a grammatical rule. This rule describes the structure of a basic Unix command. The purpose of a Unix command is to trigger the execution of a program by indicating all the information necessary for its proper execution. We can take as a principle that for every program installed on a Unix machine there corresponds a command usable from the shell that bears the name of the program and that reciprocally, every Unix command is the name of a program installed on the computer. The set of Unix commands is therefore infinite, since when you install or write a new program, this in fact adds a new command to your Unix system. However, there is a set of commands installed by default on all Unix systems. We give you on page @section-commandes-unix a list of the main commands that you can use on all Unix computers you will use.
```{bash}
#| label: fig-basic-command
#| eval: false
#| fig-cap: >
#| Basic structure of a Unix command line: a command line is divided into four main parts.
#| Only the first is mandatory, it indicates the program to use. The others allow defining
@@ -259,7 +345,7 @@ A Unix command line can be divided into four main parts (see Fig. @fig-basic-com
#### The Unix Command
A Unix command is the name of a program installed on the machine. Thus, when you execute a Unix command like `ls` or `egrep`, you are actually launching the execution of a program of the same name installed on your computer. There is therefore somewhere stored in the hard disks of the latter a file that contains the code of the program to be executed. The question that then arises is: "How does the machine manage to find the file associated with a command when it is asked to interpret it?" It is obvious that if the computer had to search each time a Unix command is executed throughout its hard disks for the file to be executed, the search time would in most cases be longer than the program's calculation time. To allow a reasonable search time, program files are only searched for in a subset of the directories existing on the machine. This subset is described by a list of directories stored in an environment variable named `PATH`. It is possible to consult this list (see example @shell-path) or to modify it with the `setenv` command. The order of appearance of directories in this list plays a role if several programs exist with the same name in different directories in the list.
A Unix command is the name of a program installed on the machine. Thus, when you execute a Unix command like `ls` or `egrep`, you are actually launching the execution of a program of the same name installed on your computer. There is therefore somewhere stored in the hard disks of the latter a file that contains the code of the program to be executed. The question that then arises is: "How does the machine manage to find the file associated with a command when it is asked to interpret it?" It is obvious that if the computer had to search each time a Unix command is executed throughout its hard disks for the file to be executed, the search time would in most cases be longer than the program's calculation time. To allow a reasonable search time, program files are only searched for in a subset of the directories existing on the machine. This subset is described by a list of directories stored in an environment variable named `PATH`. It is possible to consult this list (see example @shell-path) or to modify it with the `export` command. The order of appearance of directories in this list plays a role if several programs exist with the same name in different directories in the list.
```{bash}
#| label: shell-path
@@ -279,6 +365,7 @@ If you want to execute a program whose file is located in a directory not listed
```{bash}
#| label: shell-program
#| eval: false
#| caption: >
#| Execute a program located in a non-standard directory: Suppose we have in our main directory
#| a directory named `myprograms` in which I store all my analysis programs. In this directory,
@@ -292,6 +379,7 @@ myprograms/myscript.csh turlututu
```{bash}
#| label: shell-program-courant
#| eval: false
#| caption: >
#| Execute a program located in a non-standard directory: If the program is in the current
#| directory, it is necessary to add `./` before its name to specify its location.
@@ -307,6 +395,7 @@ Command options allow altering its operation by adjusting its parameters. Option
```{bash}
#| label: options-commande
#| eval: false
#| caption: >
#| Options modify the behavior of a program: the `egrep` command filters a text file to only
#| let through the lines of it containing an instance of the searched pattern (`Root` in our
@@ -320,10 +409,20 @@ egrep -i Root /etc/passwd
egrep --ignore-case Root /etc/passwd
```
```{bash}
#| echo: false
#| output: asis
echo "root:x:0:0:root:/root:/bin/bash"
echo "# (no output for second command)"
echo "root:x:0:0:root:/root:/bin/bash"
echo "root:x:0:0:root:/root:/bin/bash"
```
Some options require arguments, for example the `-B` or `--before-context` option of the `egrep` command allows indicating how many lines located before a line normally printed by an `egrep` command should also be printed. These options therefore require an argument specifying the number of lines to add (see example @options-with-arguments). When using the short form of the option (`-B`), it is sufficient to add this number following the option, separated or not by a space: `-B 9` or `-B9`. If you use the long form, the argument is associated with its option by the sign "=": `--before-context=9`.
```{bash}
#| label: options-with-arguments
#| eval: false
#| caption: >
#| Options can require arguments: The `-B` and `--before-context` options require as an argument
#| the number of lines of the filtered text that should be added before each of the lines that
@@ -333,10 +432,24 @@ grep -B 2 root /etc/passwd
grep --before-context=1 root /etc/passwd
```
```
ames:x:5:60:games:/usr/games:/usr/sbin/nologin
man:x:6:12:man:/var/cache/man:/usr/sbin/nologin
lp:x:7:7:lp:/var/spool/lpd:/usr/sbin/nologin
mail:x:8:8:mail:/var/mail:/usr/sbin/nologin
news:x:9:9:news:/var/spool/news:/usr/sbin/nologin
uucp:x:10:10:uucp:/var/spool/uucp:/usr/sbin/nologin
proxy:x:13:13:proxy:/bin:/usr/sbin/nologin
www-data:x:33:33:www-data:/var/www:/usr/sbin/nologin
backup:x:34:34:backup:/var/backups:/usr/sbin/nologin
list:x:38:38:Mailing List Manager:/var/list:/usr/sbin/nologin
```
It is frequent when using several options of a program in their short form to group their names behind a single "-" sign (see example @options-concat). If one of these options requires an argument, it is mandatory to place it in last position so that the argument can be added after it. If several options require arguments, it will not be possible to concatenate them into a single group. This possibility of grouping options makes it possible to simplify the writing of options but is absolutely not mandatory. It is not possible with options in their long form.
```{bash}
#| label: options-concat
#| eval: false
#| caption: >
#| Short options can be concatenated: When several short options are used, their names can
#| be concatenated behind a single "-" sign. If one of them requires an argument, it must be
@@ -345,6 +458,19 @@ It is frequent when using several options of a program in their short form to gr
grep -iB 2 Root /etc/passwd
```
```
games:x:5:60:games:/usr/games:/usr/sbin/nologin
man:x:6:12:man:/var/cache/man:/usr/sbin/nologin
lp:x:7:7:lp:/var/spool/lpd:/usr/sbin/nologin
mail:x:8:8:mail:/var/mail:/usr/sbin/nologin
news:x:9:9:news:/var/spool/news:/usr/sbin/nologin
uucp:x:10:10:uucp:/var/spool/uucp:/usr/sbin/nologin
proxy:x:13:13:proxy:/bin:/usr/sbin/nologin
www-data:x:33:33:www-data:/var/www:/usr/sbin/nologin
backup:x:34:34:backup:/var/backups:/usr/sbin/nologin
list:x:38:38:Mailing List Manager:/var/list:/usr/sbin/nologin
```
The order of appearance of arguments in a Unix command line is normally unimportant. If the order of options influences the behavior of the program, this will be specified in its manual.
#### Command Arguments
@@ -372,6 +498,7 @@ Each word in a Unix command line using one of these characters will be replaced
```{bash}
#| label: cmd-bash
#| eval: false
#| caption: Examples of using filenames with ambiguities.
ls -l
@@ -383,6 +510,16 @@ echo /[AD]*
echo /[uv]??
```
```
file1.txt file2.txt myprograms/
# (no *foo files)
bin boot dev etc home lib media mnt opt proc root run sbin srv sys tmp usr var
# (no /mach* files)
# (no /*.* files)
# (no /[AD]* files)
# (no /[uv]?? files)
```
These filenames with ambiguities are most often used with file manipulation commands such as copy (`cp` command page @unix-cp), deletion (`rm` command page @unix-rm), or the `ls` command (page @unix-ls) allowing to obtain a list of files. They are also frequently used in loops that allow launching the same Unix command on a whole series of data sets.
### Redirection of Standard Inputs-Outputs
@@ -398,6 +535,7 @@ Each of these streams has one of its ends connected to the process to allow it t
```{bash}
#| label: fig-shell-inoutput
#| eval: false
#| fig-cap: Setting the standard inputs and outputs of the shell.
```
@@ -413,6 +551,7 @@ In example @stdout, the `ls` command is executed a first time in a classic way,
```{bash}
#| label: stdout
#| eval: false
#| caption: Redirection of standard output.
ls /
@@ -421,6 +560,31 @@ ls -l
cat my_listing
```
```
bin boot dev etc home lib media mnt opt proc root run sbin srv sys tmp usr var
# (redirected to file)
total
-rw-r--r-- 1 user users 123 Jan 15 10:35 my_listing
bin
boot
dev
etc
home
lib
media
mnt
opt
proc
root
run
sbin
srv
sys
tmp
usr
var
```
In this case, the connection diagram of the standard inputs and outputs of the process executing the `ls` program is presented in Figure @fig-ls-stdout. Only the standard output *stdout* is redirected. The error output remains connected to the terminal, which will therefore continue to retransmit any error messages generated.
If the file `my_listing` does not exist, it is created and filled with the results of the command. If this file already exists, the existing file is deleted and a new file with the same name is substituted for it. You must therefore be careful: this redirection mechanism very easily allows deleting a file containing other results.
@@ -429,6 +593,7 @@ If you want to add the results generated by our program to the end of an already
```{bash}
#| label: fig-ls-stdout
#| eval: false
#| fig-cap: Redirection of the standard output of an `ls` command.
```
@@ -440,6 +605,7 @@ The redirection of standard input is materialized in the redirection part of a c
```{bash}
#| label: stdin
#| eval: false
#| caption: Redirection of standard input and standard output.
egrep or < my_listing
@@ -447,6 +613,14 @@ egrep or < my_listing > my_selection
cat my_selection
```
```
proc
sbin"
echo "# (redirected to file)"
echo "proc
sbin
```
The `egrep` command selects among the lines of text it receives on its standard input those containing a certain pattern (`or` in the case of example @stdin) to copy them to its standard output. To indicate to the process executing the `egrep` program that it should read the text to be analyzed from the file `my_listing`, it is sufficient to redirect its standard input *stdin*. Simultaneously with this redirection, it is also possible to redirect the standard output to a new file: `my_selection` in our example.
#### Redirection of Standard Output to Another Process
@@ -457,6 +631,7 @@ From a syntactic point of view, the language of a shell allows achieving this ef
```{bash}
#| label: fig-commande-tube
#| eval: false
#| fig-cap: Structure of a double command.
```
@@ -464,6 +639,7 @@ It should be noted that commands upstream of a pipe cannot redirect their standa
```{bash}
#| label: pipe
#| eval: false
#| caption: Construction of a complex command with a pipe.
ls / | grep or
@@ -471,10 +647,19 @@ ls / | grep or > my_selection
cat my_selection
```
```
proc
sbin
# (redirected to file)"
proc
sbin
```
In a complex command like the one presented in example @pipe, a process is created for each of the commands and it is just the data that flows from one process to the other (see Figure @fig-ls-egrep-pipe).
```{bash}
#| label: fig-ls-egrep-pipe
#| eval: false
#| fig-cap: Construction of a pipe between two processes.
```
@@ -486,29 +671,38 @@ The interest of a computer lies in its ability to automatically perform repetiti
Working automatically and repetitively requires using variables to store useful information that changes at each iteration. For example, if your Unix command must execute by reading its data in different files from one execution to another, you can no longer write the file name in your command since it will not always be the same.
You already know the environment variables that are set by the `setenv` command and that serve to store information relating to the configuration of your system. There are simple variables that allow you to store for the duration of your Unix session all the information you deem necessary. They are set by the `set` command. To retrieve the value contained in a variable, simply precede its name with the "$" character (see example @variable).
You already know the environment variables that are set by the `export` command and that serve to store information relating to the configuration of your system. There are simple variables that allow you to store for the duration of your Unix session all the information you deem necessary. They are set by simple assignment. To retrieve the value contained in a variable, simply precede its name with the "$" character (see example @variable).
```{bash}
#| label: variable
#| caption: Setting and displaying a variable.
set myvariable="hello world"
myvariable="hello world"
echo myvariable
echo $myvariable
```
#### The `foreach` Loop
#### The `for` Loop
For our problem, repeating the same Unix command several times by making it work on different data files, we are going to create a variable that will take in turn as value each of the elements of a list. In our case, this list will be a list of file names and it will be built using the ambiguity characters on file names presented on page @fichier-star. To build such a variable whose value changes automatically, you must not use the `set` command, but the `foreach` command. All Unix commands inserted between the `foreach` command and its associated keyword `end` are executed once for each value taken by the variable.
For our problem, repeating the same Unix command several times by making it work on different data files, we are going to create a variable that will take in turn as value each of the elements of a list. In our case, this list will be a list of file names and it will be built using the ambiguity characters on file names presented on page @fichier-star. To build such a variable whose value changes automatically, you must use the `for` command. All Unix commands inserted between the `for` command and its associated keyword `done` are executed once for each value taken by the variable.
```{bash}
#| label: boucle1
#| caption: Construction of a `foreach` loop.
#| eval: false
#| caption: Construction of a `for` loop.
echo /[mnop]*
foreach f ( /[mnop]* )
echo I am working with file $f
end
for f in /[mnop]*; do
echo "I am working with file $f"
done
```
```
media mnt opt proc"
I am working with file media
I am working with file mnt
I am working with file opt
I am working with file proc
```
## Some Essential Unix Commands in Alphabetical Order
@@ -556,14 +750,13 @@ The `bash` command allows launching the execution of a new `bash` shell that wil
#### Example of Use
```{bash}
#| label: cmd-bash
#| label: cmd-bash-2
#| eval: false
#| caption: Launch a `bash` shell.
setenv foo
export foo
export foo=bar
bash
setenv foo
export foo
export foo=baz
exit
```
@@ -588,6 +781,7 @@ bg [%job]
```{bash}
#| label: cmd-bg
#| eval: false
#| caption: Sending a job to the background. The `sleep` command does nothing except wait for the indicated number of seconds. `^Z` symbolizes pressing the `Ctrl+z` keys.
sleep 30
@@ -636,6 +830,7 @@ cd [directory_name]
```{bash}
#| label: cmd-cd
#| eval: false
#| caption: Changing directory.
pwd
@@ -693,9 +888,10 @@ chsh -s new_shell
```{bash}
#| label: cmd-chsh
#| eval: false
#| caption: Changing shell.
chsh -s /bin/tcsh
chsh -s /bin/bash
```
### `cp`: Copy Files
@@ -765,7 +961,7 @@ env [name=value ...] [command [argument ...]]
#| label: cmd-env
#| caption: Configuring your execution environment.
setenv hello "hello friends"
export hello="hello friends"
env
env hello="goodbye" env
```
@@ -1080,15 +1276,15 @@ sed [-E] program [file ...]
| `program` | A character string describing in the `sed` language the program to execute to transform the text. |
| `data_file` | The file containing the text to transform. If this argument is absent, the standard input is taken as the data source. |
### `setenv`: Set Environment Variable
{#unix-setenv}
### `export`: Set Environment Variable
{#unix-export}
Creates or modifies an environment variable. This command is specific to `tcsh`. A roundabout but simple way to check that our shell is indeed `tcsh` is to execute this command.
Creates or modifies an environment variable. This command is specific to `bash`.
#### Prototype
```bash
setenv [variable] [value]
export [variable]=[value]
```
### `sort`: Sort Lines of a File

View File

@@ -0,0 +1,320 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="210mm"
height="297mm"
id="svg3466"
sodipodi:version="0.32"
inkscape:version="0.46+devel"
sodipodi:docname="ls-stdout.svg"
inkscape:output_extension="org.inkscape.output.svg.inkscape">
<defs
id="defs3468">
<marker
inkscape:stockid="Arrow2Sstart"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow2Sstart"
style="overflow:visible">
<path
id="path4444"
style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round"
d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
transform="scale(0.3) translate(-2.3,0)" />
</marker>
<marker
inkscape:stockid="Arrow1Send"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow1Send"
style="overflow:visible;">
<path
id="path4429"
d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;marker-start:none;"
transform="scale(0.2) rotate(180) translate(6,0)" />
</marker>
<marker
inkscape:stockid="Arrow2Mend"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow2Mend"
style="overflow:visible;">
<path
id="path4441"
style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round;"
d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
transform="scale(0.6) rotate(180) translate(0,0)" />
</marker>
<marker
inkscape:stockid="Arrow1Lend"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow1Lend"
style="overflow:visible;">
<path
id="path4417"
d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;marker-start:none;"
transform="scale(0.8) rotate(180) translate(12.5,0)" />
</marker>
<inkscape:perspective
sodipodi:type="inkscape:persp3d"
inkscape:vp_x="0 : 526.18109 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_z="744.09448 : 526.18109 : 1"
inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
id="perspective3474" />
<inkscape:perspective
id="perspective3682"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective3746"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective3829"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective6738"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<marker
inkscape:stockid="Arrow1Send"
orient="auto"
refY="0"
refX="0"
id="Arrow1Send-8"
style="overflow:visible">
<path
id="path4429-5"
d="M 0,0 5,-5 -12.5,0 5,5 0,0 z"
style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none"
transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
</marker>
<inkscape:perspective
id="perspective6998"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="0.82"
inkscape:cx="458.32315"
inkscape:cy="520"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1024"
inkscape:window-height="1258"
inkscape:window-x="251"
inkscape:window-y="0" />
<metadata
id="metadata3471">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Calque 1"
inkscape:groupmode="layer"
id="layer1">
<image
y="328.25241"
x="18.182924"
id="image3684"
height="115.29269"
width="299"
sodipodi:absref="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-JFYLLU-johnny_automatic_computer_keyboard_2.png"
xlink:href="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-JFYLLU-johnny_automatic_computer_keyboard_2.png" />
<image
y="310.89874"
x="501.81705"
id="image3748"
height="200"
width="211"
sodipodi:absref="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-IHSILU-elkbuntu_Generic_Monitor.png"
xlink:href="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-IHSILU-elkbuntu_Generic_Monitor.png" />
<g
id="g3878"
transform="matrix(0.54652317,0,0,0.51254828,238.99277,-307.68767)">
<rect
y="698.24506"
x="94.3554"
height="405.71429"
width="277.14285"
id="rect2571"
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:2;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<rect
y="786.81238"
x="94.081749"
height="314.29395"
width="277.69016"
id="rect2573"
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1.99175954;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<rect
y="955.39844"
x="94.116631"
height="148.63133"
width="277.62039"
id="rect2575"
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:2.0210464;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<text
sodipodi:linespacing="125%"
id="text2577"
y="749.71008"
x="119.77839"
style="font-size:32px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
xml:space="preserve"><tspan
y="749.71008"
x="119.77839"
id="tspan2579"
sodipodi:role="line">Environement</tspan></text>
<text
sodipodi:linespacing="125%"
id="text2581"
y="1037.7681"
x="139.23932"
style="font-size:32px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
xml:space="preserve"><tspan
y="1037.7681"
x="139.23932"
id="tspan2583"
sodipodi:role="line"> ls</tspan></text>
<text
sodipodi:linespacing="125%"
id="text2585"
y="876.591"
x="161.77057"
style="font-size:32px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
xml:space="preserve"><tspan
y="876.591"
x="161.77057"
id="tspan2587"
sodipodi:role="line">Données</tspan></text>
<image
xlink:href="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-8STCLU-johnny_automatic_one_drawer_wooden_case.png"
sodipodi:absref="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-8STCLU-johnny_automatic_one_drawer_wooden_case.png"
width="237.2981"
height="149.99986"
id="image7000"
x="654.27667"
y="659.68597" />
</g>
<path
style="fill:none;stroke:#000000;stroke-width:8;stroke-linecap:butt;stroke-linejoin:round;stroke-opacity:1;display:inline;marker-start:none;marker-end:url(#Arrow1Send);stroke-miterlimit:4;stroke-dasharray:none"
d="m 196.29673,328.25241 0.8218,-242.577686 84.58879,-0.385712"
id="path3898"
inkscape:connector-type="polyline"
inkscape:connection-start="#image3684"
sodipodi:nodetypes="ccc" />
<path
style="fill:none;stroke:#000000;stroke-width:8;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:8;stroke-opacity:1;stroke-dasharray:none;marker-start:none;marker-end:url(#Arrow1Send)"
d="m 443.40182,85.928321 76.30467,-0.285841 0.99609,213.88091"
id="path5599"
inkscape:connector-type="polyline"
sodipodi:nodetypes="ccc"
inkscape:transform-center-x="10.070665"
inkscape:transform-center-y="29.220663" />
<path
style="fill:none;stroke:#000000;stroke-width:8.35659599;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:8;stroke-opacity:1;stroke-dasharray:none;marker-start:none;marker-end:url(#Arrow1Send)"
d="M 443.11969,65.404909 580.71934,64.57954"
id="path5599-7"
inkscape:connector-type="polyline"
sodipodi:nodetypes="cc"
inkscape:transform-center-x="18.309701"
inkscape:transform-center-y="1.1258372" />
<text
xml:space="preserve"
style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="-238.9709"
y="176.1861"
id="text6758"
sodipodi:linespacing="125%"
transform="matrix(-0.01895268,-0.99982038,0.99982038,-0.01895268,0,0)"
inkscape:transform-center-x="14.335966"
inkscape:transform-center-y="-37.775572"><tspan
sodipodi:role="line"
id="tspan6760"
x="-238.9709"
y="176.1861">stdin</tspan></text>
<text
xml:space="preserve"
style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="464.03152"
y="57.44215"
id="text6762"
sodipodi:linespacing="125%"
transform="matrix(0.99994591,-0.01040044,0.01040044,0.99994591,0,0)"
inkscape:transform-center-x="-25.609756"
inkscape:transform-center-y="14.067191"><tspan
sodipodi:role="line"
id="tspan6764"
x="464.03152"
y="57.44215">stdout</tspan></text>
<text
xml:space="preserve"
style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="148.56487"
y="-530.55206"
id="text6766"
sodipodi:linespacing="125%"
transform="matrix(0.0135934,0.99990761,-0.99990761,0.0135934,0,0)"><tspan
sodipodi:role="line"
id="tspan6768"
x="148.56487"
y="-530.55206">stderr</tspan></text>
<text
xml:space="preserve"
style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:100%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="581.70728"
y="130.41095"
id="text7014"
sodipodi:linespacing="100%"><tspan
sodipodi:role="line"
id="tspan7016"
x="581.70728"
y="130.41095"
style="font-size:24px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:100%;writing-mode:lr-tb;text-anchor:start;font-family:Courier;-inkscape-font-specification:Courier">mon_listing</tspan></text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 13 KiB

View File

@@ -0,0 +1,495 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="210mm"
height="297mm"
id="svg3466"
sodipodi:version="0.32"
inkscape:version="0.46+devel"
sodipodi:docname="pipe.svg"
inkscape:output_extension="org.inkscape.output.svg.inkscape">
<defs
id="defs3468">
<marker
inkscape:stockid="Arrow2Sstart"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow2Sstart"
style="overflow:visible">
<path
id="path4444"
style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round"
d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
transform="scale(0.3) translate(-2.3,0)" />
</marker>
<marker
inkscape:stockid="Arrow1Send"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow1Send"
style="overflow:visible;">
<path
id="path4429"
d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;marker-start:none;"
transform="scale(0.2) rotate(180) translate(6,0)" />
</marker>
<marker
inkscape:stockid="Arrow2Mend"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow2Mend"
style="overflow:visible;">
<path
id="path4441"
style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round;"
d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
transform="scale(0.6) rotate(180) translate(0,0)" />
</marker>
<marker
inkscape:stockid="Arrow1Lend"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow1Lend"
style="overflow:visible;">
<path
id="path4417"
d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;marker-start:none;"
transform="scale(0.8) rotate(180) translate(12.5,0)" />
</marker>
<inkscape:perspective
sodipodi:type="inkscape:persp3d"
inkscape:vp_x="0 : 526.18109 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_z="744.09448 : 526.18109 : 1"
inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
id="perspective3474" />
<inkscape:perspective
id="perspective3682"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective3746"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective3829"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective6738"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<marker
inkscape:stockid="Arrow1Send"
orient="auto"
refY="0"
refX="0"
id="Arrow1Send-8"
style="overflow:visible">
<path
id="path4429-5"
d="M 0,0 5,-5 -12.5,0 5,5 0,0 z"
style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none"
transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
</marker>
<inkscape:perspective
id="perspective6998"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective7106"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective7154"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<marker
inkscape:stockid="Arrow1Send"
orient="auto"
refY="0"
refX="0"
id="Arrow1Send-5"
style="overflow:visible">
<path
id="path4429-4"
d="M 0,0 5,-5 -12.5,0 5,5 0,0 z"
style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none"
transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
</marker>
<inkscape:perspective
id="perspective9121"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective9340"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="1.07"
inkscape:cx="114.33407"
inkscape:cy="807.71826"
inkscape:document-units="px"
inkscape:current-layer="g7088-8"
showgrid="false"
inkscape:window-width="838"
inkscape:window-height="762"
inkscape:window-x="339"
inkscape:window-y="40" />
<metadata
id="metadata3471">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Calque 1"
inkscape:groupmode="layer"
id="layer1">
<image
y="240.85634"
x="18.172258"
id="image3684"
height="82.080559"
width="214.4359"
sodipodi:absref="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-JFYLLU-johnny_automatic_computer_keyboard_2.png"
xlink:href="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-JFYLLU-johnny_automatic_computer_keyboard_2.png" />
<image
y="228.50169"
x="571.0235"
id="image3748"
height="142.38641"
width="151.32433"
sodipodi:absref="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-IHSILU-elkbuntu_Generic_Monitor.png"
xlink:href="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-IHSILU-elkbuntu_Generic_Monitor.png" />
<g
id="g7088"
transform="translate(-80,0.712675)">
<rect
y="42.899506"
x="211.51494"
height="148.04497"
width="108.6272"
id="rect2571"
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.75636965;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<rect
y="75.217682"
x="211.40768"
height="114.68572"
width="108.84171"
id="rect2573"
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.75325328;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<rect
y="136.73466"
x="211.42136"
height="54.235508"
width="108.81437"
id="rect2575"
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.76432908;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<text
transform="scale(1.036408,0.96487095)"
sodipodi:linespacing="125%"
id="text2577"
y="63.924683"
x="213.6992"
style="font-size:12.10191441px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
xml:space="preserve"><tspan
y="63.924683"
x="213.6992"
id="tspan2579"
sodipodi:role="line">Environement</tspan></text>
<text
transform="scale(1.036408,0.96487095)"
sodipodi:linespacing="125%"
id="text2581"
y="172.86385"
x="221.05904"
style="font-size:12.10191441px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
xml:space="preserve"><tspan
y="172.86385"
x="221.05904"
id="tspan2583"
sodipodi:role="line"> ls</tspan></text>
<text
transform="scale(1.036408,0.96487095)"
sodipodi:linespacing="125%"
id="text2585"
y="111.90913"
x="229.58002"
style="font-size:12.10191441px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
xml:space="preserve"><tspan
y="111.90913"
x="229.58002"
id="tspan2587"
sodipodi:role="line">Données</tspan></text>
</g>
<image
y="28.829311"
x="632.97821"
id="image7000"
height="54.734882"
width="93.009888"
sodipodi:absref="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-8STCLU-johnny_automatic_one_drawer_wooden_case.png"
xlink:href="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-8STCLU-johnny_automatic_one_drawer_wooden_case.png" />
<path
style="fill:none;stroke:#000000;stroke-width:5.71639729;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;marker-start:none;marker-end:url(#Arrow1Send);display:inline"
d="M 66.698058,256.74419 67.301171,63.298887 125.3154,62.27542"
id="path3898"
inkscape:connector-type="polyline"
sodipodi:nodetypes="ccc" />
<path
style="fill:none;stroke:#000000;stroke-width:5.716;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:8;stroke-opacity:1;stroke-dasharray:none;marker-start:none;marker-end:url(#Arrow1Send)"
d="m 241.82103,70.207201 110.95008,0.571512 3.08434,245.755007 207.75904,-0.8034"
id="path5599"
inkscape:connector-type="polyline"
sodipodi:nodetypes="cccc"
inkscape:transform-center-x="8.7851138"
inkscape:transform-center-y="20.689846" />
<path
style="fill:none;stroke:#000000;stroke-width:5.97120285;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:8;stroke-opacity:1;stroke-dasharray:none;marker-start:none;marker-end:url(#Arrow1Send)"
d="M 240.9271,53.726767 315.61039,53.13916"
id="path5599-7"
inkscape:connector-type="polyline"
sodipodi:nodetypes="cc"
inkscape:transform-center-x="13.141451"
inkscape:transform-center-y="0.80123225" />
<text
xml:space="preserve"
style="font-size:28.58198738px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="-171.87724"
y="53.146492"
id="text6758"
sodipodi:linespacing="125%"
transform="matrix(-0.01902236,-0.99615774,1.0034965,-0.01888325,0,0)"
inkscape:transform-center-x="10.281426"
inkscape:transform-center-y="-26.893646"><tspan
sodipodi:role="line"
id="tspan6760"
x="-171.87724"
y="53.146492">stdin</tspan></text>
<text
xml:space="preserve"
style="font-size:28.58198738px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="242.96147"
y="47.313225"
id="text6762"
sodipodi:linespacing="125%"
transform="matrix(1.0036225,-0.01036234,0.01043868,0.9962828,0,0)"
inkscape:transform-center-x="-18.366717"
inkscape:transform-center-y="10.014886"><tspan
sodipodi:role="line"
id="tspan6764"
x="242.96147"
y="47.313225">stdout</tspan></text>
<text
xml:space="preserve"
style="font-size:28.58198738px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="154.34219"
y="-358.42078"
id="text6766"
sodipodi:linespacing="125%"
transform="matrix(0.01364338,0.99624466,-1.003584,0.0135436,0,0)"><tspan
sodipodi:role="line"
id="tspan6768"
x="154.34219"
y="-358.42078">stderr</tspan></text>
<text
xml:space="preserve"
style="font-size:28.58198738px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:100%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="622.0321"
y="100.37435"
id="text7014"
sodipodi:linespacing="100%"
transform="scale(1.0036768,0.99633667)"><tspan
sodipodi:role="line"
id="tspan7016"
x="622.0321"
y="100.37435"
style="font-size:17.14919281px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:100%;writing-mode:lr-tb;text-anchor:start;font-family:Courier;-inkscape-font-specification:Courier">mon_listing</tspan></text>
<g
transform="translate(226.17146,0.712675)"
id="g7088-8">
<rect
y="42.899506"
x="211.51494"
height="148.04497"
width="108.6272"
id="rect2571-1"
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.75636965;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<rect
y="75.217682"
x="211.40768"
height="114.68572"
width="108.84171"
id="rect2573-1"
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.75325328;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<rect
y="136.73466"
x="211.42136"
height="54.235508"
width="108.81437"
id="rect2575-2"
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.76432908;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<text
transform="scale(1.036408,0.96487095)"
sodipodi:linespacing="125%"
id="text2577-8"
y="63.924683"
x="213.6992"
style="font-size:12.10191441px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
xml:space="preserve"><tspan
y="63.924683"
x="213.6992"
id="tspan2579-7"
sodipodi:role="line">Environement</tspan></text>
<text
transform="scale(1.036408,0.96487095)"
sodipodi:linespacing="125%"
id="text2581-3"
y="172.86385"
x="221.05904"
style="font-size:12.10191441px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
xml:space="preserve"><tspan
y="172.86385"
x="221.05904"
id="tspan2583-2"
sodipodi:role="line"> egrep</tspan></text>
<text
transform="scale(1.036408,0.96487095)"
sodipodi:linespacing="125%"
id="text2585-2"
y="111.90913"
x="229.58002"
style="font-size:12.10191441px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
xml:space="preserve"><tspan
y="111.90913"
x="229.58002"
id="tspan2587-0"
sodipodi:role="line">Données</tspan></text>
</g>
<path
style="fill:none;stroke:#000000;stroke-width:5.97120285;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:8;stroke-opacity:1;stroke-dasharray:none;marker-start:none;marker-end:url(#Arrow1Send)"
d="m 545.89674,51.701958 80.01335,-1.52064"
id="path5599-7-6"
inkscape:connector-type="polyline"
sodipodi:nodetypes="cc"
inkscape:transform-center-x="13.141451"
inkscape:transform-center-y="0.80123225" />
<text
xml:space="preserve"
style="font-size:28.58198738px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="550.80219"
y="48.482811"
id="text6762-2"
sodipodi:linespacing="125%"
transform="matrix(1.0036225,-0.01036234,0.01043868,0.9962828,0,0)"
inkscape:transform-center-x="-18.366717"
inkscape:transform-center-y="10.014886"><tspan
sodipodi:role="line"
id="tspan6764-5"
x="550.80219"
y="48.482811">stdout</tspan></text>
<path
sodipodi:type="arc"
style="fill:#ff0000;fill-opacity:1;stroke:#000000;stroke-width:8;stroke-linejoin:round;stroke-miterlimit:8;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="path7180"
sodipodi:cx="364"
sodipodi:cy="54.362183"
sodipodi:rx="20"
sodipodi:ry="22"
d="m 384,54.362183 a 20,22 0 1 1 -40,0 20,22 0 1 1 40,0 z"
transform="matrix(0.50390843,0,0,0.45809857,150.57733,27.458944)" />
<path
style="fill:none;stroke:#000000;stroke-width:5.71600008;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;marker-start:none;marker-mid:none;marker-end:url(#Arrow1Send-5)"
d="m 346.0938,53.995703 82.29449,0.36648"
id="path7182"
inkscape:connector-type="polyline"
sodipodi:nodetypes="cc" />
<text
xml:space="preserve"
style="font-size:28.58198738px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="356.31754"
y="54.221001"
id="text6758-0"
sodipodi:linespacing="125%"
transform="matrix(0.9959039,-0.02744408,0.03045135,1.0032738,0,0)"
inkscape:transform-center-x="418.77442"
inkscape:transform-center-y="329.23379"><tspan
sodipodi:role="line"
id="tspan6760-2"
x="356.31754"
y="54.221001">stdin</tspan></text>
<path
style="fill:none;stroke:#000000;stroke-width:5.716;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;stroke-miterlimit:4;stroke-dasharray:none;marker-end:url(#Arrow1Send-5)"
d="M 545.79439,63.577136 603.6,63.047303 604.6729,219.65191"
id="path9138"
inkscape:connector-type="polyline"
sodipodi:nodetypes="ccc" />
<text
xml:space="preserve"
style="font-size:28.58198738px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="137.18686"
y="-610.66376"
id="text6766-1"
sodipodi:linespacing="125%"
transform="matrix(0.01364338,0.99624467,-1.003584,0.0135436,0,0)"><tspan
sodipodi:role="line"
id="tspan6768-9"
x="137.18686"
y="-610.66376">stderr</tspan></text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 22 KiB

View File

@@ -0,0 +1,116 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="210mm"
height="297mm"
id="svg2"
sodipodi:version="0.32"
inkscape:version="0.46+devel"
sodipodi:docname="process.svg"
inkscape:output_extension="org.inkscape.output.svg.inkscape">
<defs
id="defs4">
<inkscape:perspective
sodipodi:type="inkscape:persp3d"
inkscape:vp_x="0 : 526.18109 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_z="744.09448 : 526.18109 : 1"
inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
id="perspective10" />
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="1.7255553"
inkscape:cx="335.5924"
inkscape:cy="543.18094"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1050"
inkscape:window-height="821"
inkscape:window-x="0"
inkscape:window-y="22" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Calque 1"
inkscape:groupmode="layer"
id="layer1">
<rect
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:2;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2571"
width="277.14285"
height="405.71429"
x="211.15906"
y="223.79076" />
<rect
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1.99175954;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2573"
width="277.69016"
height="314.29395"
x="210.88541"
y="312.35806" />
<rect
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:2.0210464;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2575"
width="277.62039"
height="148.63133"
x="210.92029"
y="480.94412" />
<text
xml:space="preserve"
style="font-size:32px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
x="236.58205"
y="275.2558"
id="text2577"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2579"
x="236.58205"
y="275.2558">Environement</tspan></text>
<text
xml:space="preserve"
style="font-size:32px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
x="256.04297"
y="563.31378"
id="text2581"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2583"
x="256.04297"
y="563.31378">Programme</tspan></text>
<text
xml:space="preserve"
style="font-size:32px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
x="278.57422"
y="402.13672"
id="text2585"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2587"
x="278.57422"
y="402.13672">Données</tspan></text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 4.4 KiB

View File

@@ -0,0 +1,294 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="210mm"
height="297mm"
id="svg3466"
sodipodi:version="0.32"
inkscape:version="0.46+devel"
sodipodi:docname="shell-inout.svg"
inkscape:output_extension="org.inkscape.output.svg.inkscape">
<defs
id="defs3468">
<marker
inkscape:stockid="Arrow2Sstart"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow2Sstart"
style="overflow:visible">
<path
id="path4444"
style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round"
d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
transform="scale(0.3) translate(-2.3,0)" />
</marker>
<marker
inkscape:stockid="Arrow1Send"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow1Send"
style="overflow:visible;">
<path
id="path4429"
d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;marker-start:none;"
transform="scale(0.2) rotate(180) translate(6,0)" />
</marker>
<marker
inkscape:stockid="Arrow2Mend"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow2Mend"
style="overflow:visible;">
<path
id="path4441"
style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round;"
d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
transform="scale(0.6) rotate(180) translate(0,0)" />
</marker>
<marker
inkscape:stockid="Arrow1Lend"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow1Lend"
style="overflow:visible;">
<path
id="path4417"
d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;marker-start:none;"
transform="scale(0.8) rotate(180) translate(12.5,0)" />
</marker>
<inkscape:perspective
sodipodi:type="inkscape:persp3d"
inkscape:vp_x="0 : 526.18109 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_z="744.09448 : 526.18109 : 1"
inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
id="perspective3474" />
<inkscape:perspective
id="perspective3682"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective3746"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective3829"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<inkscape:perspective
id="perspective6738"
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
inkscape:vp_z="1 : 0.5 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 0.5 : 1"
sodipodi:type="inkscape:persp3d" />
<marker
inkscape:stockid="Arrow1Send"
orient="auto"
refY="0"
refX="0"
id="Arrow1Send-8"
style="overflow:visible">
<path
id="path4429-5"
d="M 0,0 5,-5 -12.5,0 5,5 0,0 z"
style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none"
transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
</marker>
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="0.82"
inkscape:cx="410.12195"
inkscape:cy="520"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1024"
inkscape:window-height="1258"
inkscape:window-x="251"
inkscape:window-y="0" />
<metadata
id="metadata3471">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Calque 1"
inkscape:groupmode="layer"
id="layer1">
<image
y="328.25241"
x="18.182924"
id="image3684"
height="115.29269"
width="299"
sodipodi:absref="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-JFYLLU-johnny_automatic_computer_keyboard_2.png"
xlink:href="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-JFYLLU-johnny_automatic_computer_keyboard_2.png" />
<image
y="310.89874"
x="501.81705"
id="image3748"
height="200"
width="211"
sodipodi:absref="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-IHSILU-elkbuntu_Generic_Monitor.png"
xlink:href="/var/folders/5N/5NFz3SvzHiSgXVQaph86gU++m12/-Tmp-/ocal-IHSILU-elkbuntu_Generic_Monitor.png" />
<g
id="g3878"
transform="matrix(0.54652317,0,0,0.51254828,240.99277,-307.68767)">
<g
id="g3867">
<rect
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:2;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2571"
width="277.14285"
height="405.71429"
x="94.3554"
y="698.24506" />
<rect
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1.99175954;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2573"
width="277.69016"
height="314.29395"
x="94.081749"
y="786.81238" />
<rect
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:2.0210464;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2575"
width="277.62039"
height="148.63133"
x="94.116631"
y="955.39844" />
<text
xml:space="preserve"
style="font-size:32px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
x="119.77839"
y="749.71008"
id="text2577"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2579"
x="119.77839"
y="749.71008">Environement</tspan></text>
<text
xml:space="preserve"
style="font-size:32px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
x="139.23932"
y="1037.7681"
id="text2581"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2583"
x="139.23932"
y="1037.7681">Shell Unix</tspan></text>
<text
xml:space="preserve"
style="font-size:32px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans;-inkscape-font-specification:Bitstream Vera Sans"
x="161.77057"
y="876.591"
id="text2585"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2587"
x="161.77057"
y="876.591">Données</tspan></text>
</g>
</g>
<path
style="fill:none;stroke:#000000;stroke-width:8;stroke-linecap:butt;stroke-linejoin:round;stroke-opacity:1;display:inline;marker-start:none;marker-end:url(#Arrow1Send);stroke-miterlimit:4;stroke-dasharray:none"
d="m 196.29673,328.25241 0.8218,-242.577686 84.58879,-0.385712"
id="path3898"
inkscape:connector-type="polyline"
inkscape:connection-start="#image3684"
sodipodi:nodetypes="ccc" />
<path
style="fill:none;stroke:#000000;stroke-width:8;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:8;stroke-opacity:1;stroke-dasharray:none;marker-start:none;marker-end:url(#Arrow1Send)"
d="m 443.40182,85.928321 76.30467,-0.285841 0.99609,213.88091"
id="path5599"
inkscape:connector-type="polyline"
sodipodi:nodetypes="ccc"
inkscape:transform-center-x="10.070665"
inkscape:transform-center-y="29.220663" />
<path
style="fill:none;stroke:#000000;stroke-width:8;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:8;stroke-opacity:1;stroke-dasharray:none;marker-start:none;marker-end:url(#Arrow1Send)"
d="m 444.39104,56.213449 171.69385,-1.575451 2.2422,248.002082"
id="path5599-7"
inkscape:connector-type="polyline"
sodipodi:nodetypes="ccc"
inkscape:transform-center-x="21.764296"
inkscape:transform-center-y="38.134532" />
<text
xml:space="preserve"
style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="-238.9709"
y="176.1861"
id="text6758"
sodipodi:linespacing="125%"
transform="matrix(-0.01895268,-0.99982038,0.99982038,-0.01895268,0,0)"
inkscape:transform-center-x="14.335966"
inkscape:transform-center-y="-37.775572"><tspan
sodipodi:role="line"
id="tspan6760"
x="-238.9709"
y="176.1861">stdin</tspan></text>
<text
xml:space="preserve"
style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="119.80942"
y="-637.53284"
id="text6762"
sodipodi:linespacing="125%"
transform="matrix(-0.02597904,0.99966249,-0.99966249,-0.02597904,0,0)"><tspan
sodipodi:role="line"
id="tspan6764"
x="119.80942"
y="-637.53284">stdout</tspan></text>
<text
xml:space="preserve"
style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Times;-inkscape-font-specification:Times"
x="148.56487"
y="-530.55206"
id="text6766"
sodipodi:linespacing="125%"
transform="matrix(0.0135934,0.99990761,-0.99990761,0.0135934,0,0)"><tspan
sodipodi:role="line"
id="tspan6768"
x="148.56487"
y="-530.55206">stderr</tspan></text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 12 KiB

View File

@@ -0,0 +1,365 @@
---
title: "Unix Basics"
format:
revealjs:
theme: beige
transition: fade
width: 1280
height: 720
center: true
---
## Why Learn Unix?
- Foundational philosophy for modern computing
- Powers most of the digital world
- Born at AT&T's Bell Labs in late 1960s
- Design principles: simplicity, modularity
## Unix Today
- **Certified Unix**: macOS
- **Unix-like Systems**: GNU/Linux, BSD variants
- **Linux**: Dominant Unix-like OS
- Understanding Unix = understanding DNA of modern OS
## Unix System Overview
**Multi-user, Multitasking Operating System**
```{mermaid}
graph TD
A[OS Kernel] --> B[User 1 Process]
A --> C[User 2 Process]
A --> D[User 3 Process]
B --> E[File System]
C --> E
D --> E
style A fill:#2e86ab,color:#fff
style B fill:#a23b72,color:#fff
style C fill:#f18f01,color:#fff
style D fill:#c73e1d,color:#fff
style E fill:#3c8d5f,color:#fff
```
## File System Structure
**Hierarchical Tree Organization**
```{mermaid}
graph TD
Root[/] --> etc["/etc<br/>config files"]
Root --> home["/home<br/>user directories"]
Root --> usr["/usr<br/>system software"]
Root --> var["/var<br/>variable data"]
home --> user1[/user1/]
home --> user2[/user2/]
user1 --> docs[Documents]
user1 --> downloads[Downloads]
style Root fill:#2e86ab,color:#fff;
style etc fill:#a23b72,color:#fff;
style home fill:#f18f01,color:#fff;
style usr fill:#c73e1d,color:#fff;
style var fill:#3c8d5f,color:#fff;
```
## File Naming Rules
**Allowed Characters:**
- Letters (a-z, A-Z), Numbers (0-9)
- Recommended: `.`, `%`, `-`, `_`, `:`, `=`
**Key Rules:**
- **Case sensitive**: `File.txt` ≠ `file.txt` ≠ `FILE.TXT`
- **No leading dash**: `-file` causes issues (use `./-file`)
- **Hidden files**: Start with `.` (e.g., `.bashrc`)
**Best Practices:**
```bash
good_file.txt # Clear and safe
data-set-01.csv # Descriptive with hyphens
project_config # No extension needed
```
## Globbing - Pattern Matching
**Wildcard Characters:**
```bash
* # Any sequence of characters
? # Any single character
[abc] # Any character in set
[a-z] # Any character in range
```
**Practical Examples:**
```bash
ls *.txt # All text files
ls report?.pdf # report1.pdf, reportA.pdf
ls [abc]*.log # a.log, b_data.log, c-backup.log
ls image[0-9].jpg # image0.jpg through image9.jpg
```
## Advanced Globbing
**Combining Patterns:**
```bash
ls *.{txt,md} # All .txt AND .md files
ls project_{dev,prod} # project_dev, project_prod
ls file[!0-9]* # Files NOT starting with digit
```
**Use in Commands:**
```bash
cp *.txt backup/ # Copy all text files
rm temp_*.log # Remove temporary logs
chmod +x *.sh # Make all scripts executable
```
**Pattern Expansion:**
```bash
echo *.py # Shows what patterns match
ls data_202{3,4}*.csv # Multiple year patterns
```
## Globbing vs Regular Expressions
**Key Differences:**
- **Globbing**: File matching (`ls *.txt`)
- **Regex**: Text pattern matching (`grep "^A" file.txt`)
**Remember:** Globbing happens **before** command execution!
## File Permissions
**Three categories × Three rights**
```bash
-rwxr-xr-- # Owner: read, write, execute
# Group: read, execute
# Others: read only
```
```{=html}
<svg viewBox="0 0 600 200" xmlns="http://www.w3.org/2000/svg">
<defs>
<pattern id="read" patternUnits="userSpaceOnUse" width="10" height="10">
<rect width="10" height="10" fill="#2e86ab" opacity="0.3"/>
<line x1="0" y1="0" x2="10" y2="10" stroke="#2e86ab" stroke-width="1"/>
</pattern>
<pattern id="write" patternUnits="userSpaceOnUse" width="10" height="10">
<rect width="10" height="10" fill="#a23b72" opacity="0.3"/>
<rect x="2" y="2" width="6" height="6" fill="#a23b72" opacity="0.6"/>
</pattern>
<pattern id="execute" patternUnits="userSpaceOnUse" width="10" height="10">
<rect width="10" height="10" fill="#f18f01" opacity="0.3"/>
<circle cx="5" cy="5" r="3" fill="#f18f01" opacity="0.6"/>
</pattern>
</defs>
<!-- Owner Permissions -->
<g transform="translate(50, 50)">
<rect x="0" y="0" width="150" height="100" fill="#2e86ab" opacity="0.1" stroke="#2e86ab" stroke-width="2"/>
<text x="75" y="30" text-anchor="middle" font-family="Arial, sans-serif" font-weight="bold" font-size="16" fill="#2e86ab">Owner</text>
<g transform="translate(40, 50)">
<rect x="0" y="0" width="20" height="20" fill="url(#read)"/>
<text x="10" y="35" text-anchor="middle" font-family="monospace" font-size="12" fill="#2e86ab">r</text>
<rect x="30" y="0" width="20" height="20" fill="url(#write)"/>
<text x="40" y="35" text-anchor="middle" font-family="monospace" font-size="12" fill="#a23b72">w</text>
<rect x="60" y="0" width="20" height="20" fill="url(#execute)"/>
<text x="70" y="35" text-anchor="middle" font-family="monospace" font-size="12" fill="#f18f01">x</text>
</g>
</g>
<!-- Group Permissions -->
<g transform="translate(225, 50)">
<rect x="0" y="0" width="150" height="100" fill="#a23b72" opacity="0.1" stroke="#a23b72" stroke-width="2"/>
<text x="75" y="30" text-anchor="middle" font-family="Arial, sans-serif" font-weight="bold" font-size="16" fill="#a23b72">Group</text>
<g transform="translate(40, 50)">
<rect x="0" y="0" width="20" height="20" fill="url(#read)"/>
<text x="10" y="35" text-anchor="middle" font-family="monospace" font-size="12" fill="#2e86ab">r</text>
<rect x="30" y="0" width="20" height="20" fill="#f5f5f5" stroke="#ccc" stroke-width="1"/>
<text x="40" y="35" text-anchor="middle" font-family="monospace" font-size="12" fill="#999">-</text>
<rect x="60" y="0" width="20" height="20" fill="url(#execute)"/>
<text x="70" y="35" text-anchor="middle" font-family="monospace" font-size="12" fill="#f18f01">x</text>
</g>
</g>
<!-- Others Permissions -->
<g transform="translate(400, 50)">
<rect x="0" y="0" width="150" height="100" fill="#f18f01" opacity="0.1" stroke="#f18f01" stroke-width="2"/>
<text x="75" y="30" text-anchor="middle" font-family="Arial, sans-serif" font-weight="bold" font-size="16" fill="#f18f01">Others</text>
<g transform="translate(40, 50)">
<rect x="0" y="0" width="20" height="20" fill="url(#read)"/>
<text x="10" y="35" text-anchor="middle" font-family="monospace" font-size="12" fill="#2e86ab">r</text>
<rect x="30" y="0" width="20" height="20" fill="#f5f5f5" stroke="#ccc" stroke-width="1"/>
<text x="40" y="35" text-anchor="middle" font-family="monospace" font-size="12" fill="#999">-</text>
<rect x="60" y="0" width="20" height="20" fill="#f5f5f5" stroke="#ccc" stroke-width="1"/>
<text x="70" y="35" text-anchor="middle" font-family="monospace" font-size="12" fill="#999">-</text>
</g>
</g>
</svg>
```
## Process Concept
**Program vs Process**
```{=html}
<svg viewBox="0 0 500 200" xmlns="http://www.w3.org/2000/svg">
<defs>
<marker id="arrowhead" markerWidth="10" markerHeight="7" refX="9" refY="3.5" orient="auto">
<polygon points="0 0, 10 3.5, 0 7" fill="#2e86ab"/>
</marker>
<filter id="shadow" x="-20%" y="-20%" width="140%" height="140%">
<feDropShadow dx="2" dy="2" stdDeviation="3" flood-color="#000000" flood-opacity="0.3"/>
</filter>
</defs>
<!-- Program (Static) -->
<g transform="translate(50, 50)">
<rect x="0" y="0" width="180" height="100" rx="10" fill="#2e86ab" filter="url(#shadow)"/>
<rect x="5" y="5" width="170" height="90" rx="8" fill="#ffffff"/>
<text x="90" y="35" text-anchor="middle" font-family="Arial, sans-serif" font-weight="bold" font-size="18" fill="#2e86ab">Program</text>
<text x="90" y="60" text-anchor="middle" font-family="Arial, sans-serif" font-size="14" fill="#666">Static Code</text>
<text x="90" y="80" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" fill="#888">(On Disk)</text>
</g>
<!-- Arrow -->
<path d="M 240 100 L 310 100" stroke="#2e86ab" stroke-width="3" marker-end="url(#arrowhead)"/>
<text x="275" y="95" text-anchor="middle" font-family="Arial, sans-serif" font-size="14" fill="#2e86ab">execution</text>
<!-- Process (Dynamic) -->
<g transform="translate(320, 50)">
<rect x="0" y="0" width="180" height="100" rx="10" fill="#a23b72" filter="url(#shadow)"/>
<rect x="5" y="5" width="170" height="90" rx="8" fill="#ffffff"/>
<text x="90" y="35" text-anchor="middle" font-family="Arial, sans-serif" font-weight="bold" font-size="18" fill="#a23b72">Process</text>
<text x="90" y="60" text-anchor="middle" font-family="Arial, sans-serif" font-size="14" fill="#666">Running Instance</text>
<text x="90" y="80" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" fill="#888">(In Memory)</text>
</g>
</svg>
```
## Shell Environment
**Your Command Interface**
```{=html}
<svg viewBox="0 0 500 250" xmlns="http://www.w3.org/2000/svg">
<defs>
<filter id="shellShadow" x="-20%" y="-20%" width="140%" height="140%">
<feDropShadow dx="3" dy="3" stdDeviation="4" flood-color="#000000" flood-opacity="0.2"/>
</filter>
</defs>
<!-- Main Shell Container -->
<rect x="100" y="30" width="300" height="160" rx="15" fill="#f8f9fa" stroke="#2e86ab" stroke-width="3" filter="url(#shellShadow)"/>
<!-- Shell Title -->
<text x="250" y="60" text-anchor="middle" font-family="Arial, sans-serif" font-weight="bold" font-size="20" fill="#2e86ab">Shell Environment</text>
<!-- Command Input Area -->
<rect x="130" y="80" width="240" height="30" rx="5" fill="#ffffff" stroke="#a23b72" stroke-width="2"/>
<text x="140" y="100" text-anchor="start" font-family="monospace" font-size="14" fill="#333">$ ls -l *.txt</text>
<!-- Input Source -->
<g transform="translate(50, 150)">
<rect x="0" y="0" width="80" height="40" rx="8" fill="#2e86ab" opacity="0.8"/>
<text x="40" y="20" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" fill="#fff">Keyboard</text>
<text x="40" y="35" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#fff">Input</text>
</g>
<!-- Output Destination -->
<g transform="translate(370, 150)">
<rect x="0" y="0" width="80" height="40" rx="8" fill="#a23b72" opacity="0.8"/>
<text x="40" y="20" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" fill="#fff">Terminal</text>
<text x="40" y="35" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#fff">Output</text>
</g>
<!-- Arrows -->
<path d="M 130 150 L 180 120" stroke="#2e86ab" stroke-width="2" marker-end="url(#arrowhead)"/>
<path d="M 320 120 L 370 150" stroke="#a23b72" stroke-width="2" marker-end="url(#arrowhead)"/>
<!-- Process Execution -->
<rect x="200" y="120" width="100" height="40" rx="5" fill="#f18f01" opacity="0.8"/>
<text x="250" y="140" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" fill="#fff">Process</text>
<text x="250" y="155" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#fff">Execution</text>
</svg>
```
## Command Structure
```bash
command [options] [arguments] [redirections]
```
**Examples:**
```bash
ls -l /home # List with details
grep "error" log.txt # Search pattern
find . -name "*.txt" # Find files
```
## Input/Output Redirection
**Controlling Data Flow**
```{mermaid}
flowchart LR
A[Input File<br/>data.txt] --> B{Command<br/>program}
B --> C[Output File<br/>results.txt]
style A fill:#2e86ab,color:#fff
style B fill:#a23b72,color:#fff
style C fill:#f18f01,color:#fff
```
## Pipes - Command Chaining
**Connect processes together**
```bash
cat file.txt | grep "error" | sort | uniq
```
```{mermaid}
flowchart LR
A[cat<br/>Reads file] -->|stdout| B[grep<br/>Filters text]
B -->|stdout| C[sort<br/>Orders data]
C -->|stdout| D[uniq<br/>Removes duplicates]
style A fill:#2e86ab,color:#fff
style B fill:#a23b72,color:#fff
style C fill:#f18f01,color:#fff
style D fill:#3c8d5f,color:#fff
```
## Essential Commands
| Category | Commands | Purpose |
|----------|----------|---------|
| **Files** | `ls, cp, mv, rm, mkdir` | Manage files and directories |
| **Navigation** | `cd, pwd` | Move around file system |
| **Text** | `cat, grep, head, tail, wc` | View and search text |
| **Process** | `ps, kill, &, bg, fg` | Manage running programs |
| **Help** | `man, --help` | Get command information |
## Getting Started
**Next Steps:**
- Practice basic file operations
- Learn command combinations with pipes
- Study pattern matching with wildcards
- Explore shell scripting for automation
- Use `man` pages for detailed help
**Remember:** Unix mastery comes through practice!

View File

@@ -0,0 +1,484 @@
---
title: "Unix Essentials — Modern Bash Edition"
subtitle: "A practical, colorblindfriendly introduction"
author: "Your Name"
format:
html:
toc: true
toc-depth: 3
code-tools: true
code-fold: false
theme: cosmo
smooth-scroll: true
include-in-header:
text: |
<style>
.quarto-figure img, .quarto-figure svg {
display: block;
margin: 0 auto;
vertical-align: middle;
overflow: visible;
}
</style>
execute:
echo: true
warning: false
message: false
mermaid:
theme: neutral
background: transparent
width: 100%
page-layout: article
---
# Introduction to Unix
Unix is a family of operating systems and a set of design ideas—small programs that do one thing well, text as a universal interface, and easy composition through pipes. Those ideas power Linux servers, macOS, iOS, Android (via Linux), and most cloud infrastructure today. Learning Unix is learning the lingua franca of modern computing.
## Certified UNIX vs. Unixlike
“UNIX” is a trademark of The Open Group for systems that pass the POSIX/SUS conformance tests. macOS is certified; Linux distributions and BSDs are “Unixlike”—they follow the same model and standards. For our purposes, you can treat them similarly.
> This course uses **bash** exclusively. Commands and syntax target modern GNU/*BSD/macOS shells and core utilities. When an option is GNUspecific, well note it.
# Users and Accounts
Each person has a **user account** (username/login) with a numeric **UID**, a **primary group**, a **home directory**, and a **default shell**. User account metadata lives in `/etc/passwd` (user list) and `/etc/shadow` (password hashes, not worldreadable).
```{bash}
#| label: ex-passwd-head
#| eval: false
#| caption: Inspecting the user database (first lines of /etc/passwd).
head -15 /etc/passwd
```
# The Unix File System
The filesystem is a single rooted hierarchy (`/`). Directories are nodes; files are leaves; symbolic links add extra edges (making it a DAG).
![](fs.svg){style="display:block;margin:0;padding:0;" fig-cap="A simplified Unix filesystem tree. The highlighted path resolves to `/etc/passwd`." #fig-fs-unix}
Common toplevel directories:
- `/etc` system configuration
- `/var` variable state (logs, spool, caches)
- `/bin`, `/usr/bin` essential and additional executables
- `/usr`, `/usr/local` the main system and locally installed software
- `/home` (or `/Users` on macOS) user homes
## Filenames and Rules
- Case matters: `Foo.txt` ≠ `foo.txt`.
- Avoid spaces and exotic punctuation in names; prefer letters, digits, `. - _`.
- Names starting with `.` are “hidden” (e.g., `~/.bashrc`).
## Links
Two kinds of links:
- **Hard link**: an additional directory entry pointing to the same inode (same file). Cannot span filesystems; not for directories (with rare admin exceptions).
- **Symbolic link**: a small file that points to a path (can cross filesystems).
![](fs-link.svg){fig-cap="Symbolic link creates an extra path to the same target." #fig-fs-link}
## `.` and `..`
Every directory contains entries `.` (itself) and `..` (parent). They make relative navigation and scripting concise.
![](fs-spdir.svg){fig-cap="Special entries `.` and `..` help navigate without absolute paths." #fig-fs-spdir}
## Current Working Directory and Relative Paths
Your **current working directory** (CWD) is where relative paths are resolved. Use `pwd` to show it and `cd` to change it.
```{bash}
#| eval: false
pwd
cd /usr
pwd
cd - # jump back
```
## Permissions (Mode), Ownership, and Umask
Each file has an **owner** (user), a **group**, and three permission triplets (r,w,x) for **user**, **group**, and **others**:
```{bash}
#| eval: false
# long listing shows mode, owner, group, size, date, name
ls -l /bin/bash
# change permissions: add user execute, remove group write
chmod u+x,g-w script.sh
# change owner/group (requires privileges)
sudo chown alice:science data.tsv
# show and set default creation mask
umask # e.g., 0022
umask 0002 # collaborative group-writable defaults
```
# Processes
A **program** is code on disk; a **process** is a running instance with its own memory, environment, and open file descriptors. Each process has a **PID** and a **PPID** (parent PID).
```{bash}
#| eval: false
ps aux | head -5
pstree -a | head -20 # on macOS: brew install pstree; or use 'pgrep -lf .'
```
## The Process “Anatomy”
- **Code** (the program image)
- **Data/Heap/Stack**
- **Environment** (variables like `PATH`, `HOME`)
- **Standard streams**: `stdin` (0), `stdout` (1), `stderr` (2)
![](process.svg){fig-cap="A process has code, data, environment, and standard streams." #fig-process-anatomy}
## Lifecycle and Inheritance
Processes are created by **fork/exec**. Children inherit the parents environment and open descriptors unless changed. When a child exits, it becomes a **zombie** until the parent reaps it.
```{mermaid}
%%| echo: false
%%| code-fold: false
graph TD
A["Parent process"] -->|fork| B["Child (COW)"]
B -->|exec| C["New program image"]
C -->|exit| D{Parent waits}
D -- yes --> E["Child reaped"]
D -- no --> F["Zombie until parent waits"]
```
# The Shell (bash)
The shell is a command interpreter and a scripting language. Well use **bash** only.
## Structure of a Command Line
```text
command [OPTIONS...] [ARGUMENTS...] [REDIRECTIONS/PIPES]
```
- **Command**: executable name or path
- **Options**: short `-l` or long `--long`
- **Arguments**: files, patterns, values
- **Redirections/Pipes**: `>`, `>>`, `<`, `2>`, `|`, `|&`, `<<<`
```{bash}
#| label: ex-path
#| caption: PATH lists directories searched for commands, left to right.
echo "$PATH"
command -v bash # show full path to the executable bash will run
```
If a program isnt on `PATH`, run it via a path (absolute or relative):
```{bash}
#| eval: false
./mytool --help
/home/alice/bin/mytool --version
```
## Modern Note on `grep`
`egrep` and `fgrep` are deprecated. Use `grep -E` (extended regex) and `grep -F` (fixed strings).
```{bash}
#| eval: false
grep -E 'root|daemon' /etc/passwd
grep -Fi 'error' /var/log/system.log
```
# Globs (Filename Patterns)
The shell expands patterns **before** running the command:
| Pattern | Meaning |
|---|---|
| `*` | any string (including empty) |
| `?` | any single char |
| `[abc]` | any of listed chars |
| `{a,b,c}` | brace expansion (not a glob; bash feature) |
```{bash}
#| eval: false
echo *.txt
ls -ld /[uv]??
printf '%s\n' project/{data,docs,src}
```
# Redirection and Pipes
Standard streams: `stdin` (0), `stdout` (1), `stderr` (2).
![](shell-inout.svg){fig-cap="Default streams: keyboard → stdin; stdout/stderr → terminal." #fig-shell-inoutput}
## Redirect to/From Files
```{bash}
#| eval: false
ls / > listing.txt # stdout to file (overwrite)
ls / >> listing.txt # append
grep -E 'log' < listing.txt # stdin from file
grep -E 'log' listing.txt > matches.txt 2> errors.log
```
## Pipelines
`|` connects stdout of left command to stdin of right command. Use `|&` to pipe both stdout and stderr (bash).
![](commande-tube.svg){fig-cap="A twostage pipeline: stdout of cmd1 becomes stdin of cmd2." #fig-commande-tube}
```{bash}
#| eval: false
ls -l /usr/bin | head -n 5
journalctl -u ssh |& grep -Ei 'fail|error' # GNU/Linux
```
![](ls-stdout.svg){fig-cap="Redirecting `ls` output into a file." #fig-ls-stdout}
![](gnome-fs-regular.svg){fig-cap="Regular file."}
![](gnome-fs-directory.svg){fig-cap="Directory."}
![](gnome-fs-home.svg){fig-cap="Home directory icon."}
![](gnome-fs-regular.svg){fig-cap="Regular file (again, for legend grouping)."}
![](gnome-fs-slink.svg){fig-cap="Symbolic link (legend)."}
# Loops, Variables, and Scripting
## Variables
Create with `name=value`. Read with `$name`. Export to children with `export name`.
```{bash}
#| label: ex-vars
greeting="hello world"
echo "$greeting"
export PATH="$HOME/bin:$PATH"
```
## `for` Loops
```{bash}
#| eval: false
for f in /var/log/*.log; do
echo "Checking: $f"
grep -Eci 'error|warning' "$f"
done
```
## Safer Bash
- Always quote expansions: `"$var"`
- Enable strict mode in scripts:
```bash
set -Eeuo pipefail
IFS=$'\n\t'
```
- Prefer `mktemp` for temp files
- Use `printf` instead of `echo` for exact output
## ColorBlindFriendly Tips
Use **shapes**, **labels**, and **line styles** rather than relying solely on color in outputs and diagrams. In Mermaid use dashed/solid edges and different node shapes:
```{mermaid}
%%| echo: false
%%| code-fold: false
flowchart LR
classDef solid stroke-width:2;
classDef dashed stroke-dasharray: 5 5, stroke-width:2;
A([File]):::solid --> B{{Grep}}:::dashed
B --> C[[Matches]]
```
# Essential Commands (Modernized, Bashcentric)
Below are concise prototypes. Use `--help` and `man` for details.
## `awk` — Pattern scanning and processing
```bash
awk [-F SEP] 'PROGRAM' [FILE...]
```
- `-F` field separator. Example: `awk -F: '{print $1,$3}' /etc/passwd`
## `bash` — The shell
```bash
bash # start a new interactive shell
bash script.sh # run a script
```
## `bg` / `fg` / `jobs` — Job control
```bash
sleep 60 & # run in background
jobs # list jobs
fg %1 # bring job 1 to foreground
bg %1 # resume job 1 in background
```
## `cat` — Concatenate files
```bash
cat file1 [file2 ...] > out
```
## `cd` — Change directory
```bash
cd [DIR] # no arg: go to $HOME
```
## `chmod` — Change permissions
```bash
chmod [-R] MODE FILE...
chmod u+rwx,g+rx,o-rwx FILE
```
## `chsh` — Change login shell
```bash
chsh -s /bin/bash
```
## `cp` — Copy files
```bash
cp [-R] SRC... DEST
```
## `diff` — Text diffs
```bash
diff -u old.txt new.txt | less
```
## `env` / `export` — Environment
```bash
env | sort
export VAR=value
```
## `grep` — Search text (replaces `egrep`/`fgrep`)
```bash
grep [-E|-F] [-iR] PATTERN [FILE...]
```
## `head` / `tail` — File ends
```bash
head -n 20 FILE
tail -n 50 FILE
tail -f /var/log/syslog # follow
```
## `join` — Join lines on a field
```bash
join -1 1 -2 1 file1 file2
```
## `kill` — Send signals
```bash
kill -SIGTERM PID
kill -9 PID # last resort
kill -l # list signals
```
## `ln` — Create links
```bash
ln FILE LINKNAME # hard link
ln -s TARGET LINKNAME # symlink
```
## `ls` — List files
```bash
ls -la
ls -ltrh /var/log
```
## `man` — Manuals
```bash
man ls
man -k network # search by keyword
```
## `mkdir` — Make directories
```bash
mkdir -p project/{data,docs,src}
```
## `mv` — Move/rename
```bash
mv old new
mv file*.txt dir/
```
## `paste` — Merge lines side by side
```bash
paste file1 file2
```
## `ps` — Process status
```bash
ps aux | grep -E '[n]ginx'
ps -U "$USER" -o pid,ppid,stat,cmd
```
## `pwd` — Current directory
```bash
pwd
```
## `rm` — Remove files (dangerous)
```bash
rm [-rf] PATH...
```
> Tip: Use `trash`/`gio trash` on desktops when possible.
## `sed` — Stream editor
```bash
sed -E 's/old/new/g' FILE
```
## `sort` / `uniq` — Sorting and deduping
```bash
sort -u names.txt
sort -k2,2n data.tsv | uniq -c
```
## `wc` — Counts
```bash
wc -lwc FILE
```
# Practice: Putting It Together
```{bash}
#| eval: false
# Find the 10 most common failed SSH sources today (GNU/Linux example)
journalctl -u ssh --since today \
| grep -Ei 'failed|authentication failure' \
| awk '{print $(NF)}' \
| sort | uniq -c | sort -k1,1nr | head -10
```