Skip to content

Instantly share code, notes, and snippets.

View michahell's full-sized avatar

Michael Trouw michahell

View GitHub Profile
@joshangell
joshangell / PhpStorm-and-Gridsome.md
Last active December 21, 2022 10:13
Quick and dirty explanation of how to get autocomplete, syntax highlighting etc when using Gridsome in PhpStorm.

PhpStorm

  1. Make sure your gridsome dev server is running: cd frontend and then yarn dev or npm run dev
  2. Install JS GraphQL plugin: https://jimkyndemeyer.github.io/js-graphql-intellij-plugin/
  3. Select everything inside <page-query>, click the light bulb icon, choose "Inject language or reference" and select GraphQL, like this:

NOTE: you only have to do this once and then all your .vue files will support GraphQL queries inside <page-query> tags.

@akrisiun
akrisiun / tips_lsof.sh
Last active March 10, 2025 19:09 — forked from tianchaijz/tips_lsof.sh
Shell command lsof : see open files and ports; Selection is OR by default, use -a for AND; Tested on OSX
# filter LISTEN - faster variant
lsof -anP -i4 -sTCP:LISTEN
# exclude UDP
lsof -anP -i4 -sTCP:LISTEN | grep TCP
# lsof with ports sort:
lsof -anP -i4 -sTCP:LISTEN | grep -v UDP | awk {'printf("%18s %-12s %8s %s %s %s\n", $9,$1,$2,$4,$3,$10)'} | sort -u
# docker-ps