Snippets

SNP 001–153

Loosely organized collection of code snippets. Maybe you'll find something useful here.

Showing 13 of 153 snippets

  1. SNP013

    Get query parameters in Nuxt

    Read the GET request query parameters in your code.

    1 line of js in 1 block, 2 lines of explanation.

    #249 js nuxt
  2. SNP012

    Concat IDs into a single field in SQL

    Here is how to merge multiple SQL rows into one, values separated by a comma.

    1 line of sql in 1 block, 1 line of explanation.

    #951 sql
  3. SNP011

    Add more VSFTPD virtual user accounts

    How to add more virtual user accounts to your VSFTPD on linux.

    7 lines of sh in 3 blocks, 3 lines of explanation.

    #419 cmd
  4. SNP010

    Mount samba share on Ubuntu 20.04 server

    How to mount samba shares on the latest Ubuntu LTS release.

    3 lines of sh in 3 blocks, 4 lines of explanation.

    #2B1 cmd
  5. SNP009

    Compress and extract TAR files on linux

    How to compress and extract TAR files on linux with gzip easily.

    3 lines of sh in 3 blocks, 8 lines of explanation with 4 notes.

    #65B cmd
  6. SNP008

    File sizes on linux

    See files sizes easily in megabyte or gigabyte values.

    2 lines of sh in 2 blocks, 3 lines of explanation.

    #513 cmd
  7. SNP007

    Reset MariaDB root password on linux

    An easy way to reset the password of the root user on linux.

    11 lines of sh in 8 blocks, 11 lines of explanation.

    #139 cmd
  8. SNP006

    Fix MariaDB missing tables on Manjaro/Arch linux

    Here is how to fix the missing tables in MariaDB that you may encounter on a fresh install on Manjaro or Arch linux.

    8 lines of sh in 5 blocks, 8 lines of explanation.

    #931 cmd
  9. SNP005

    List all users and groups on linux

    Simple way to check your user list with your groups.

    3 lines of sh in 3 blocks, 3 lines of explanation.

    #962 cmd
  10. SNP004

    Chown basics on linux

    Change the owner of files on a linux machine.

    4 lines of sh in 4 blocks, 4 lines of explanation.

    #523 cmd
  11. SNP003

    Select all text in input field on click the Vue JS way

    Comparing the traditional javascript way with the Vue event you can use.

    2 lines of html in 2 blocks, 3 lines of explanation.

    #24B js vue
  12. SNP002

    Ubuntu run command in the background

    Sometimes you just need to run commands in the background.

    1 line of sh in 1 block, 1 line of explanation.

    #123 cmd
  13. SNP001

    Certbot snippets

    Useful commands for SSL cert generation with Certbot.

    4 lines of sh in 3 blocks, 3 lines of explanation.

    #26A cmd