HNHacker News
TopNewBestAskShowJobs

m-r-r

6 karma · joined January 28, 2013

submissionscomments
m-r-r··on The wake effect: As wind farms expand, some can ‘steal’ each others’ wind
This sounds a lot like the plot of The Horde of Counterwind by Alain Damasio
m-r-r··on Zip Function Solution: Haskell, Elixir, JavaScript, Python, Vlang
Yes, the JavaScript implementation doesn't works if the second array contains 'false', 'null', 'undefined', '0' or 'NaN'.

Here is my implementation of the 'zip' function in modern JavaScript. It is similar to the Vlang version, but it is generic over the number of arrays :

  const zip = (...arrays) => {
    const length = Math.min(...arrays.map((array) => array.length));
    return Array.from({ length }, (_, i) => arrays.map((array) => array[i]));
  };
m-r-r··on Browser Extensions Standard
> The answer was "nothing really" - it worked out of the box for the main functionality.

Do you mean Chrome supports Promises like Firefox does? Last time I checked, the Chrome APIs were using callbacks for all asynchronous operations.

m-r-r··on Show HN: Poor man's Google Docs
Neovim
m-r-r··on The Caveman Guide to Parenting
What is "french style parenting" ?
m-r-r··on The Benefits of Failing at French
> I suspect that it would take me many months or perhaps even years of immersion and full-time speaking and thinking in French to get to the point of being able to construct most sentences in "natural French" structure on the first try.

If you have difficulty learning French, I suggest learning another language with a similar "structure", such as Esperanto.

I'm a French native speaker, and I'm currently learning Esperanto. I find the two languages very similar in their way of constructing sentences, but the later one if a lot easier to learn: conjugation and agreement, in particular, are much simpler, and the absence of suppletion (a verb and its derivative always share the same root) helps greatly for memorizing the vocabulary.

m-r-r··on Announcing the new Rust package manager, Cargo
They already started to write some code: https://github.com/carlhuda/cargo
m-r-r··on French Court Allows Reverse Engineering of Skype Protocol
In the case of Skype, your right: Skype can probably change their protocols and ruin the work of the reverse enginners. But this would have a price: Skype users would have to install the last version of the client to be able to communicate with their contacts. If Microsoft started to modify the Skype protocol each week, the users would probably get tired of updating their client weekly and they would use another software.

For others proprietary softwares, breaking the compatibility with old versions is hardly conceivable: If Photoshop or AutoCAD where suddenly unable to use read and write the terabytes of data created by their users, those users would probably throw their PC through the window and never buy again a proprietary software...

m-r-r··on Quickly navigate your filesystem from the command line
I don't understand the advantage of using handwritten function instead of the shell builtins. The `mark` function could be replaced by `alias -g`, `jump` could be replaced by `cd` and `unmark` could be replaced by `unalias` :

    % cd ~/Dev/W3/m-r-r.github.io
    % alias -g :blog="$PWD"
    % jekyll build -d /tmp/out/ && cd /tmp/out
    % ./index.html
    % cd :blog
    % pwd
    /home/m-r-r/Dev/W3/m-r-r.github.io
    % alias -g
    :blog='/home/m-r-r/Dev/W3/m-r-r.github.io'
    :dev='/home/m-r-r/Dev'
    :c='/home/m-r-r/Dev/C'
    :python='/home/m-r-r/Dev/Python'
    :vim='/home/m-r-r/.vim'
In addition, this method works with any shell command:

    % pwd
    /tmp/out
    % make -C :blog publish
    % git clone git://git.complang.org/ragel.git `echo :c`/ragel
    % vim `echo :vim`/templates/\*.rl
On the other side, the aliases are not saved at exit unless you write a function to do it:

    % tail -n 15 ~/.zshrc
    function aliases {
        (
            alias -L -r
            alias -L -g
            alias -L -s
        ) | uniq
    } 

    function save-aliases {
        aliases > ~/.zsh_aliases
    }

    if [ -f ~/.zsh_aliases ]; then 
        . ~/.zsh_aliases
    fi
m-r-r··on Practical Typography
> Edit 2: Another thing, regarding the 1.25 to 1.45 line-height he recommends. I feel like it's a lawyer's thing. Anything smaller than 1.5 looks very clamped, and most times people use 1.5 to 1.75.

It depends of the font and the font size: sometimes, 1.3 is too much.

m-r-r··on A Dark Room - minimalist text-based game
Wow. This game is really addictive.