“””
That's right, if you attempt to parse HTML with regular expressions, you're succumbing to the temptations of the dark god Cthulhu's … er … code.
“””
Re:Tosheets, utility to send stdin to Google sheets
by jldugger on Saturday November 18, 2017 @02:11AM
(#15728103)
Of course, if it's anything like HTML, the formatting will vary over time that you really want a more permissive parser like BeautifulSoup. I haven't found a cli interface, so I briefly wrote my own ages ago: https://github.com/jldugger/dotfiles/blob/master/bin/select.....
Re:Tosheets, utility to send stdin to Google sheets
by heptathorp on Saturday November 18, 2017 @10:00AM
(#15729165)
Do NOT use r̔ͩegͩ̾ͪͥͪeͮ͊ͨ̓xͫ͆͆̓ ͤt͊͗o̒̾͋ͬ̾̚ ͆̌͌̄p͠a͟r̐̎͆̽̄ͭ́se̒ͥ ͕̪̻̭̭̺̳ͣͬͪͫͪj̞̲ͤ̚s̡̳̟̤̳̖̤͒̋ͣ͊ͤ͗̿oͬ̀͆n̮̳͚̝̩͙͔̈͋ ̮͕̩̼̔̾̈̄̋ͦ́́̚ͅĤ̷̝̯̝ͯ̈́ͣ̔ͪ̊ͬ͜͡Eͬͧ҉̜̰̲̩̰̝̠̥ ̶̯̯͚̗̪̭̘ͨͩͭ̎ͧͮCͪ҉̖͍͔͚͚̯͕Ơ̰̻̂̅̋̇̓̅͌M̸̭̱̭̥͆̽ͨͦÊ̸̴̢̪͚̮̲̜̙̍ͤ͋̾ͦS̛̗̟͙͍̹͈̳ͣ͑̏̓ͤͦ̽
Re:Tosheets, utility to send stdin to Google sheets
by thesandlord on Saturday November 18, 2017 @11:10AM
(#15729523)
Yeah logger or fluentd are definitely better long term solutions. I wanted something that was no frills and minimal config for ad-hoc situations. Other's on my team found it useful so I open sourced it.
Re:Tosheets, utility to send stdin to Google sheets
by reificator on Saturday November 18, 2017 @12:05AM
(#15727847)
When you run this utility, it forwards stdin to Google Sheets.
Should you pipeline stdout from somewhere else to this utility, the contents of that stdout will be forwarded to Google Sheets.
It is correct to say either that you are forwarding stdin or that you are forwarding stdout. It is therefore not correct to say that it does not forward stdin, because the source code explicitly refers to stdin. That's likely the reason for the [Fight Club]s the GP is receiving.
That's basically a mini JSON parser in 48 characters.
https://blog.codinghorror.com/parsing-html-the-cthulhu-way/
“”” That's right, if you attempt to parse HTML with regular expressions, you're succumbing to the temptations of the dark god Cthulhu's … er … code. “””
https://github.com/thesandlord/logpipe
For example, this uses datamash (https://www.gnu.org/software/datamash/) to sum column 2 of a CSV ("-t,"), then log the output:
Bonus: In depth code review for this package: https://youtu.be/c5ufcpTGIJM
We need more utilities like this that help integrate apps and web services between themselves and the Unix environment.
"Pipes to the web" should be like this. Not bloted a UI with forms that perform premade actions with your web apps data.
It is stdout for the previous process in the pipeline and stdin for the tosheets itself.
EDIT: Tosheets -> tosheets
From "tosheets"'s stdin to sheets.
Your project ruins my English
Should you pipeline stdout from somewhere else to this utility, the contents of that stdout will be forwarded to Google Sheets.
It is correct to say either that you are forwarding stdin or that you are forwarding stdout. It is therefore not correct to say that it does not forward stdin, because the source code explicitly refers to stdin. That's likely the reason for the [Fight Club]s the GP is receiving.
Please don't comment about the voting on comments. It never does any good, and it makes boring reading.