Score:-2

Can you execute multiple commands in the shell without the use of '&&', '||' or ';'?

lb flag

Without the use of '&&', '||' and ';' - Can you write a 2-line Linux script that lists all files (even ones hidden) in the current directory and the parent of the working directory and the /boot directory (in this order), in long format?

Raffa avatar
jp flag
Related: https://askubuntu.com/q/1446565
Score:1
tn flag

With full path as required:

find . .. /boot -type f -maxdepth 1 -exec readlink -f {} +

or of instead you need the output of ls -l:

ls -la . .. /boot
Artur Meinild avatar
vn flag
This output doesn't make any sense, as it prefixes the current path in front of everything - and where to you see the requirement for full path?
Artur Meinild avatar
vn flag
You didn't answer from where you got the requirement for full path.
Gilles Quenot avatar
tn flag
OP said `in long format` Maybe not well asked, but I guess it's full path
Artur Meinild avatar
vn flag
And I guess it's "long format" as stated in `man ls` with the `-l` switch. And now your output is recursive, listing all files in subdirectories, which wasn't asked for as well.. I'm just giving up, have fun!
Gilles Quenot avatar
tn flag
Added `-maxdepth 1`
Paballo Mogane avatar
lb flag
Thanks. I'll try that. I am however still confused.
Gilles Quenot avatar
tn flag
What do you mean by confused?
Paballo Mogane avatar
lb flag
Thought about using "ls -aln && ls -aln .. && ls -aln /boot" but again for my purposes I can't use '&&', '||' or ';'.
Gilles Quenot avatar
tn flag
Have you tested my commands? Does it works?
Paballo Mogane avatar
lb flag
basically I need a command that'll give the result of what the above (my above comment) command would've had I been able to just write that.
Paballo Mogane avatar
lb flag
Yes I tried your command but unfortunately didn't return what I needed it to.
Gilles Quenot avatar
tn flag
Your response is quite vague. Thanks to elaborate/paste on https://www.toptal.com/developers/hastebin
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.