Better HN
topnewbestaskshowjobs
Log inSign up

sdovan1

118 karma · joined Aug 13, 2024 (2y ago) · 32 submissions

Submissions

comment 5mo ago · link · parent

If your environment is POSIX, testing scripts with tool written in POSIX shell, like shellspec[1], might also be a choice.

[1] https://shellspec.info/

comment 8mo ago · link · parent

I guess the Discussion on Hacker News href should be "https://news.ycombinator.com/item?id=47514603" instead of "news.ycombinator.com/item?id=47514603"

comment 8mo ago · link · parent

Sometimes I wonder why we need to invent another DSL. (or when should we?)

At work, we have an XML DSL that bridges two services. It's actually a series of API calls with JSONPath mappings. It has if-else and goto, but no real math (you can only add 1 to a variable though) and no arrays. Debugging is such a pain, makes me wonder why we don't just write Java.

comment 11mo ago · link · parent

Overriding HOME variable is neat! Make things much easier.

comment 11mo ago · link · parent

We usually work on the VM with daily-built ISO. For example, I would compile and upload Java program to the frontend team member's VM, and type "srt" for "systemctl restart tomcat."

comment 11mo ago · link · parent

It's not obvious, but the shitt-p is borrowed from an anime character. So it should pronounce like sheet-p: https://ipa-reader.com/?text=%C9%95it%CB%90opi%CB%90

comment 11mo ago · link · parent

I often need to login to colleagues' machines at work, but I find that their settings are not what I am familiar with. So I wrote an SSH wrapper in POSIX shell which tars dotfiles into a base64 string, passes it to SSH, and decodes / setups on the remote temp directory. Automatically remove when session ends.

Supported: .profile, .vimrc, .bashrc, .tmux.conf, etc.

This idea comes from kyrat[1]; passing files via a base64 string is a really cool approach.

[1]: https://github.com/fsquillace/kyrat/

8.

Show HN: Shittp – Volatile Dotfiles over SSH(github.com ↗)

136 points · by sdovan1 · 11mo ago · 85 comments

comment 11mo ago · link · parent

FWIW, it's HTML ruby tag, not the language.

https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/...

comment 11mo ago · link · parent

A dotfiles carrier for SSH session called shittp[1], inspired by kyrat[2]

[1] https://github.com/FOBshippingpoint/shittp

[2] https://github.com/fsquillace/kyrat

comment 11mo ago · link · parent

> The next time you’re about to name your project after your favorite anime character, pause. Ask yourself: “Would a civil engineer name a bridge support system this way?” If the answer is no, choose a better name.

I'm creating a dotfiles to remote SSH session tool in shell. At first, I wanted to call it "sship", but that name was already taken. Something like "ssh-dotfiles-carrier" felt too long for a command, and abbreviating it to "sdc" would lose the meaning.

So yes, I eventually named it "shitt-p" (character of Hitman Reborn!), since I wanted it to relate to "sh"...

comment 11mo ago · link · parent

- Java Design Patterns

https://java-design-patterns.com/

13.

Spring Boot Startup Analyzer(github.com ↗)

3 points · by sdovan1 · 1y ago · discuss

14.

ShellSpec: BDD unit testing framework for shell scripts(shellspec.info ↗)

1 points · by sdovan1 · 1y ago · discuss

comment 1y ago · link · parent

I've worked with a hospital, their electric medical records are written in XML, and use XSLT to render HTML.

comment 1y ago · link · parent

I have three different way to open file with vim: v: vim (or neovim, in my case) vv: search/preview and open file by filename vvv: search/preview and open file by its content

    alias v='nvim'
    alias vv='f=$(fzf --preview-window "right:50%" --preview "bat --color=always {1}"); test -n "$f" && v "$f"'
    alias vvv='f=$(rg --line-number --no-heading . | fzf -d: -n 2.. --preview-window "right:50%:+{2}" --preview "bat --color=always --highlight-line {2} {1}"); test -n "$(echo "$f" | cut -d: -f1)" && v "+$(echo "$f" | cut -d: -f2)" "$(echo "$f" | cut -d: -f1)"'

comment 1y ago · link · parent

JIRA web eats all my memory on Firefox, so laggy that pressing a button takes 3 or 5 seconds, not to mention page transitions. It only becomes usable when I add the uBlock Origin rule[1]:

  yourcomany.atlassian.net##+js(aeld, /^(?:mousemove|pointermove|pointerout|pointerover|touchmove)$/)
[1] https://community.atlassian.com/forums/Jira-questions/Re-Re-...

comment 1y ago · link · parent

Hiroshi Abe [1] is a Japanese actor whose official website is run by a fan. The site has a nostalgic look with a minimal design (40kB, images included) and is still actively maintained today.

Instead of ping 8.8.8.8, some will test their internet connection with Hiroshi Abe's homepage because of the speed. There are even challenges where people try to speedrun the site or conversely, make it load as slowly as possible [2].

Google translated page: https://abehiroshi-la-coocan-jp.translate.goog/?_x_tr_sch=ht...

[1] https://en.wikipedia.org/wiki/Hiroshi_Abe_(actor)

[2] https://www.youtube.com/watch?v=FKjBw_jEcZk

19.

Fastest website in Japan – Hiroshi Abe's homepage(abehiroshi.la.coocan.jp ↗)

2 points · by sdovan1 · 1y ago · 2 comments

comment 1y ago · link · parent

I have a function in .bashrc to read the pod in browser:

  read_pod_html() {
    local html=$(mktemp --suffix '.html')
    pod2html --css='https://www.w3.org/StyleSheets/Core/parser.css?doc=XML&family=7' "$1" > "$html"
    /usr/bin/x-www-browser "$html"
  }

21.

Embedding documentation in shell script (2007)(bahut.alma.ch ↗)

1 points · by sdovan1 · 1y ago · 1 comment

22.

SpecTcl: GUI Builder for Tcl/Tk(spectcl.sourceforge.net ↗)

2 points · by sdovan1 · 1y ago · discuss

comment 1y ago · link · parent

I never really used browser bookmarks until I discovered Firefox's bookmark keyword feature [1]. It basically eliminates the search step. For example, I set "pr" to the GitHub pull request page. Just press Alt + D to focus the address bar, type the keyword, and hit Enter.

[1] https://support.mozilla.org/en-US/kb/bookmarks-firefox#w_how...

24.

Show HN: Mencrouche – A Hackable On-Demand Homepage(github.com ↗)

2 points · by sdovan1 · 1y ago · discuss

comment 1y ago · link · parent

I uploaded a photo and it took around 20 seconds. Maybe a loading indicator would help.

comment 1y ago · link · parent

Here is my favorite one: https://youtu.be/aFbuSShYKpc

comment 1y ago · link · parent

Thanks! I thought this was impossible. Gonna try it out today.

Edit: I successfully signed the key on AMO. Here are the steps:

    Get an access token from https://addons.mozilla.org/developers/addon/api/key/
    In manifest.json, add browser_specific_settings.gecko.id and set it to something like "myext@example.com"
    Run command: web-ext sign --api-key=<jwt-issuer> --api-secret=<jwt-secret> --channel=unlisted
    That command will upload your extension to AMO. After an automatic review, you can download the .xpi file from AMO.
That said, it's not ideal for me since I make extensions for work. Looks like a human reviewer can check your code at any time.

comment 1y ago · link · parent

I have to reinstall my personal extension every time Firefox restarts. It's so annoying that I ended up writing an AutoHotKey script just to automate it (go to about:debugging#/runtime/this-firefox -> load temporary extension -> select manifest.json). Glad to see the announcement!

comment 1y ago · link · parent

The trigger for me to start practicing touch typing was when I saw a classmate trying to log into her Gmail on a classroom PC. I was shocked at how fast she did it. I started with 10FastFingers and keybr, then stick with monkeytype and typeracer. Not sure if it's made me more productive, but it feels good when your fingers can keep up with your thoughts.

For folks who want to learn typing, I recommend Jashe's Typing Guide: https://docs.google.com/document/d/1L-P68VDSGlpLM5A9tfRvWFoh...

12