From 8c12928cc59b5a0b1d9aa6aada2772d0d2320542 Mon Sep 17 00:00:00 2001 From: Frans Kaashoek Date: Thu, 25 Jul 2019 06:50:12 -0400 Subject: [PATCH] First draft of first lab assignment? --- labs/xv6.html | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/labs/xv6.html b/labs/xv6.html index fcbb234..2f6a4ae 100644 --- a/labs/xv6.html +++ b/labs/xv6.html @@ -178,6 +178,44 @@ initial file system. You just ran one of them: ls.
  • Don't recurse into "." and "..". +

    Optional: support regular expressions in name matching. Grep has some + primitive support for regular expressions. + +

    xargs

    + +

    Write a simple version of the UNIX xargs program: read lines from + standard in and run a command for each line, supplying the line as + arguments to the command. The following example illustrates xarg's + behavior: +

    +    $ xargs echo bye
    +    hello too
    +    bye hello too
    +    
    +    $
    +  
    + Note that the command here is "echo bye" and the additional + arguments are "hello too", making the command "echo bye hello too", + which outputs "bye hello too". + +

    xargs and find combine well: +

    +    find . b | xargs grep hello
    +  
    + will run "grep hello" on each file named b in the directories below ".". + +

    Some hints: +

    + +

    Optional: modify the shell

    Modify the shell to support wait.