Search Results

Search: Posts Made By: me2
7,771
Posted By Aia
It fails because you are trying to create those...
It fails because you are trying to create those in `/' and you are not root.
Remove the `/' in front of directories in the script
7,771
Posted By Corona688
-p is required, yes, or I wouldn't have put it...
-p is required, yes, or I wouldn't have put it there.

if you already have a file named 'boo', it will fail. delete it.
7,771
Posted By frans
No need to mkdir -p /foo if you already mkdir -p...
No need to mkdir -p /foo if you already mkdir -p /foo/dir1 as the -p option creates parents.

#!/bin/bash
for d1 in boo doo foo; do
for d2 in dir1 dir2; do
mkdir -p /$d1/$d2
...
7,771
Posted By Corona688
mkdir -p /boo /boo/dir1 /boo/dir2 /doo/dir1...
mkdir -p /boo /boo/dir1 /boo/dir2 /doo/dir1 /doo/dir2 /foo /foo/dir1 /foo/dir2
touch /boo/boo_file /boo/dir1/file1 /boo/dir2/file1 /doo/dir1/file1 /doo/dir2/file1 /doo/doo_file /foo/dir1/file1...
Showing results 1 to 4 of 4

 
All times are GMT -4. The time now is 05:04 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy