Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Show HN: Twelve Days of Shell (cmdchallenge.com)
82 points by zoidb on Nov 30, 2020 | hide | past | favorite | 23 comments


Meta: The twelve days start on Christmas Day (25th):

* https://en.wikipedia.org/wiki/Twelve_Days_of_Christmas

The time period before-hand is Advent (from the Latin to come):

* https://en.wikipedia.org/wiki/Advent


I had fun. These are a great, gentle intro to powerful tools.

One recommendation: Add a "What?" accordion entry that just states in plain speech what exactly you want done, without giving away the how. For a few of these I read the prompt and was like "uh..." then clicked learn and was like "oh all they want is find -type f".

Also, small nit, "find ./place-for-pipers -type f -name "piper" | xargs grep -i 'piping'" wasn't accepted due to the filenames being prefixed to the output. I feel like this is one of the benefits of piping it all through a single grep (grep, knowing the context of multiple input files, gives you useful output). Obviously you can massage both solutions to give the others' text output, but I just felt a little cheated that my response wasn't marked correct.


Thanks for the feedback!

> One recommendation: Add a "What?" accordion entry that just states in plain speech what exactly you want done, without giving away the how. For a few of these I read the prompt and was like "uh..." then clicked learn and was like "oh all they want is find -type f".

Yeah this is a common complaint, because either the "learn" section gives away too much. I think I will just add more hints underneath the challenge like I did recently for #8 https://12days.testing.cmdchallenge.com/#/12days_8


> Also, small nit, "find ./place-for-pipers -type f -name "piper" | xargs grep -i 'piping'" wasn't accepted due to the filenames being prefixed to the output. I feel like this is one of the benefits of piping it all through a single grep (grep, knowing the context of multiple input files, gives you useful output). Obviously you can massage both solutions to give the others' text output, but I just felt a little cheated that my response wasn't marked correct.

Hm, yeah we can probably just search for the filenames and ignore everything else to make it a little more forgiving.


you can add -h to grep, which won't print the filenames (this is what I did an it accepted the answer).


Love it. I do think that the "learn" section should always be open. For me (FF) after the first challenge it's closed by default which leaves just a command line and no clear direction.


There seems to be a bug on mobile safari for iPhone. I can’t type more than one word so can’t progress past the grep command on 2


Same here, I’ll try later from PC, it’s a nice idea.


Heh, I somehow crashed the server with `grep -ie '^the' night-....`, and the error message appeared to be cached, so I had to go with `grep -ei '^the.' night-...`. Then I tried a `ls /proc` and got a rate limiting error. I think I'm not in the target audience, but it's cute!


Very nice and very educational! I'm kind of ashamed to learn only now that I can move a file without having to explicitly specify the destination file name.


thanks! glad you enjoyed it.

I had some downtime last weekend so thought I would create a Christmas edition of an old project https://cmdchallenge.com. It's a little bit more gentle of an introduction to shell than the main site.


Fun! But I think I found a bug: If you hit enter without any input then it crashes and pegs a CPU core at 100% (in firefox on Linux).


Kind of fun, although to me there seems to be a bit too much guesswork as to what you're actually supposed to do. For example the puzzle for day 8 (and especially day 9) doesn't really tell me anything about what I'm actually supposed to achieve, and clicking "learn" to find it out actually gives the solution outright.


good point, I will add a hint to #8


   Unable to process command - got response: {"message":"Internal Server Error"}
Heh. \ is not a valid entry.


yeah i saw a lot of those errors :( it calls a lexical parser on the input which doesn't like it.


Wish history of previous commands and output were kept like a standard shell to scroll through and copy-paste things


^P and ^R both work


Love it. I never knew ls took arguments! Shows how much time I spend in the terminal :)


Doesn't work in Safari 13.0.2

SyntaxError: Invalid character '\ud801'


These were quite fun!


These are like a Christmas themed bash koans.

I love it.


"Javascript is required".

Right...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: