This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
os_cp:files_processes [2025/03/12 21:03] jkonczak |
os_cp:files_processes [2026/03/12 01:00] (current) jkonczak [Directories] |
||
|---|---|---|---|
| Line 28: | Line 28: | ||
| ~~Exercise.#~~ Create the following directory tree: | ~~Exercise.#~~ Create the following directory tree: | ||
| - | <html><pre style="margin-top:-1.2em"> | + | <html><pre style="margin-top:-1.2em; padding:0.25em 0.5em; line-height:100%"> |
| . | . | ||
| ├── foo | ├── foo | ||
| - | │ ├── baz | + | │ ├── bar |
| - | │ │ └── bar | + | │ │ └── baz |
| - | │ └── bar | + | │ └── baz |
| └── foobaz | └── foobaz | ||
| └── bar | └── bar | ||
| </pre></html> | </pre></html> | ||
| - | ~~Exercise.#~~ Remove ''foo/baz'' directory | + | ~~Exercise.#~~ Remove ''foo/bar'' directory |
| ==== Hard and soft links ==== | ==== Hard and soft links ==== | ||
| Line 49: | Line 49: | ||
| To create a hard link, one can use **''ln //source// //destination//''**.\\ | To create a hard link, one can use **''ln //source// //destination//''**.\\ | ||
| To create a symlink, one can use **''ln -s //source// //destination//''**. | To create a symlink, one can use **''ln -s //source// //destination//''**. | ||
| + | |||
| + | ++ Illustration of hard links and soft links | | ||
| + | <html><object id="svg-object" data="/jkonczak/_media/os_cp:files_processes:soft-_hard-_links.svg" type="image/svg+xml"></object></html> | ||
| + | ++ | ||
| ~~Exercise.#~~ Create a file ''file1'' with some contents. Create a hard link called ''file2'' of the file ''file1''. Modify ''file2''. Display ''file1''. | ~~Exercise.#~~ Create a file ''file1'' with some contents. Create a hard link called ''file2'' of the file ''file1''. Modify ''file2''. Display ''file1''. | ||