goawk
marcel
goawk | marcel | |
---|---|---|
19 | 13 | |
1,890 | 332 | |
- | - | |
7.2 | 9.3 | |
18 days ago | 6 days ago | |
Go | Python | |
MIT License | GNU General Public License v3.0 only |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
goawk
- GoAWK, an Awk interpreter written in Go (2018)
-
The Awk Programming Language, Second Edition
TIL: GoAWK [1] - A POSIX-compliant AWK interpreter written in Go, with CSV support.
[1]: https://github.com/benhoyt/goawk
- Looking for a script for csv file
-
Anyone else doing compiler work in Golang?
Another nice project that I have used from time to time (and a very good source for insight) is the awk interpreter written in go https://github.com/benhoyt/goawk
-
Tool to interact with CSV
No, I want exactly the opposite - it should be a , b,c as a single string field containing a literal comma, and c. For example, https://github.com/benhoyt/goawk has csv support. https://github.com/benhoyt/goawk/blob/master/docs/csv.md - more info.
-
Why does awk parse '1&&x=1' as '1&&(x=1)' not '(1&&x)=1' when '&&' is high precedence than '='?
I've had a go at solving this in this PR -- feedback welcome. I don't love it, but oh well, it solves the problem at hand. Your comment pointed me in the right direction, thanks again.
-
Looking for programming languages created with Go
There are quite a few re-implementations of scripting languages like Lua in Go. I've written an AWK interpreter in Go.
-
Oracle DB support in Benthos
github.com/benhoyt/goawk -> this library lets you embed an AWK runtime in your applications, very easy to use and useful for enabling some powerful scripting in things you build
-
Brian Kernighan adds Unicode support to Awk (May, 2022)
Yes, that's right. With my simplistic UTF-8-based implementation it turned length() -- for example -- from O(1) to O(N), turning O(N) algorithms which use length() into O(N^2). See this issue: https://github.com/benhoyt/goawk/issues/93
Similar with substr() and other string functions, which when operating as bytes are O(1), but become O(N) when trying to count the number of codepoints as UTF-8.
GNU Gawk has a fancier approach, which stores strings as UTF-8 as long as it can, but converts to UTF-32 if it needs to (eg: the string is non-ASCII and you call substr).
It looks like Brian Kernighan's code has the same issue with length() and substr(). I'm going to try to email him about this, as I think it's kind of a performance blocker.
-
Ask HN: Is having a Personal blog/brand worth it for you?
I'm not sure if it was via my personal website or just my GitHub profile, but I got my current job at Canonical due to the CTO there reaching out about my GoAWK project (https://github.com/benhoyt/goawk). I get regular recruitment emails because I have my CV/resume online: most of them are very low-effort, but 1 in 20 or something are interesting emails where the recruiter has actually looked at my website and will tailor it personally. I also just enjoy technical writing, and get joy out of sharing it on HN. So it's "worth it" for me.
marcel
-
Generating graphs from the marcel command line
Marcel is one of the pipe-objects-instead-of-strings shells (https://marceltheshell.org).
Here's a blog post showing how to use marcel to generate graphs directly from the command line.
https://www.marceltheshell.org/post/generating-graphs-from-t...
-
Xonsh: Python-powered, cross-platform, Unix-gazing shell
Check out marcel (https://marceltheshell.org). It's yet another pipe-objects-instead-of-strings shell (like nushell). Unlike nushell, you pipe Python values. Marcel has no sublanguages (like awk, sed, ...). Instead, when logic is needed, you write Python code, delimited by parens. So:
(USER)
-
Marcel the Shell
It is a useful correction. This project predates the release of the movie: https://github.com/geophile/marcel/commit/bb6adacbb6b3a683ce...
-
Object SHell
Check out marcel: https://marceltheshell.org, and https://github.com/geophile/marcel. Both marcel and nushell start with the idea of piping structured data instead of strings, which is incredibly powerful. (This also applies to osh. I am the author of osh and marcel.)
Marcel (and osh) rely on Python types and language where typical shells have sublanguages. So instead of awk or find and their sublanguages, you just use Python. Instead of piping strings, you pipe streams of Python values.
Marcel lets you use Python on the commmand line. It also has an API which allows you to use shell-like commands inside of Python programs.
-
Shshsh is a bridge connects Python and shell
I wrote a shell, marcel, that pipes Python values instead of strings: https://marceltheshell.org.
It also does the inverse, allowing you to run marcel commands from Python, e.g. https://www.marceltheshell.org/scripting-1
-
The Case for Nushell
Check out my entry, marcel: https://marceltheshell.org.
E.g., find the newest vlc instance and kill it (a command that an acquaintance needs frequently, for some reason):
ps | select (p: p.name == 'vlc') | sort (p: p.create_time) | tail 1 | (p: p.signal(9))
- The Awk Programming Language, Second Edition
What are some alternatives?
bytehound - A memory profiler for Linux.
awk-vm - A virtual machine and assembler written in AWK.
tsv-utils - eBay's TSV Utilities: Command line tools for large, tabular data files. Filtering, statistics, sampling, joins and more.
asm - scriptable runtime-writable livecd / hardware wrangler
awka - Revive awka - Awk to C Compiler
busybox-w32 - WIN32 native port of BusyBox.
intellij-awk - The missing IntelliJ IDEA language support plugin for AWK
iterable-subprocess - Python context manager to communicate with a subprocess using iterables: for when data is too big to fit in memory and has to be streamed
tumblelog - A static tumblelog generator available as both a Perl and Python version
ioccc-obfuscated-c-contest - IOCCC International Obfuscated C code contest entries
awk - One true awk
carbon - :black_heart: Create and share beautiful images of your source code