Skip to content

Comment on hr for your terminal

Comments

If you like this idea and are stuck in Windows, this does the same thing:

    @set @jScript=1;/*
    @for /f "tokens=1,2" %%w in ('mode con:') do @if "%%w" == "Columns:" set cols=%%x
    @cscript /noLogo /E:jScript  "%~f0" %cols% %1 =
    @Goto :EOF
    */line='';while(line.length<WScript.Arguments(0))line+=WScript.Arguments(1);
    WScript.StdOut.Write(line.substr(0,WScript.Arguments(0)));
Save as hr.cmd and stick it somewhere in your path.
AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.