Skip to content

Instantly share code, notes, and snippets.

View rvanzon's full-sized avatar

Richard van Zon rvanzon

View GitHub Profile
@rvanzon
rvanzon / 0_reuse_code.js
Created May 2, 2017 07:44
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@rvanzon
rvanzon / nuxt.config.js
Last active September 1, 2022 13:25
A way to use vue-chartjs as a plugin of Nuxt.js
// just an example. A cleaner way is to wrap the showLine-stuff in a dedicated component
<template>
<div>
<my-line v-if="showLine" :data="lineData" :options="options">
</div>
</template>
<script>
export default {
data () {
@rvanzon
rvanzon / readme.md
Last active November 8, 2017 21:08
Using Framework7-Vue from GitHub (instead of NPM)
  1. create a directory to place the framework.
  2. clone the repository git clone https://github.com/nolimits4web/Framework7-Vue
  3. cd Framework7-Vue
  4. npm install
  5. npm run dist
  6. go to your project and remove the Framework7-Vue: npm remove Framework7-Vue
  7. link the new package you just build: npm link <path to Framework7-Vue>

That's it!

@rvanzon
rvanzon / README.md
Last active December 2, 2018 13:52
Ubuntu 18.x - server basic install

Install a basic Ubuntu server

Version 0.1

It does:

  • Changes the port of the SSH server.
  • Adds an admin user.
  • Adds the user to SUDO-ers and disables the need of a password.
  • Adds that SSH-port to UFW and enables it.
@rvanzon
rvanzon / f7hotreload.js
Last active March 22, 2019 10:19
Framework 7 backdrop remover and reopener when used with hot reload (HRM)
export default function ($f7, reopenPopup = true) {
if (module.hot) {
module.hot.addStatusHandler(status => {
if (status === 'idle') {
const activePopup = document.querySelector('.modal-in')
// next tick
setTimeout(() => {
// remove all popup backdrops if all popups are closed
if (!document.querySelectorAll('.modal-in').length) {
@rvanzon
rvanzon / macos-audit.sh
Last active March 12, 2026 16:26
macos-audit.sh
#!/usr/bin/env bash
# macOS Audit Script
# ------------------
# Purpose: Collects key security and system information from a macOS workstation.
# Usage: Run this script to generate a plain-text audit report for compliance, troubleshooting, or inventory.
# Output: Creates a timestamped .txt file with device details, FileVault, Firewall, Updates, Tailscale, and Bitwarden status.
set -euo pipefail
ts_print(){ printf "%s %s\n" "$(date '+%F %T')" "$*"; }
g(){ printf "%s \033[32m%s\033[0m\n" "$(date '+%F %T')" "$1"; }