Skip to content

Instantly share code, notes, and snippets.

View krzemienski's full-sized avatar

Nick Krzemienski krzemienski

View GitHub Profile
@Jswizzy
Jswizzy / InstallingSwift.md
Last active February 26, 2024 12:04
Swift Install Instruction 20.04

Installing Swift on Ubuntu 20.04

1. Install Depencies

“clang”[ˈklæŋ] is the compiler based on LLVM for C, C++, Objective-C, and Objective-C++. clang is needed to install in order to Swift. Run the following code in Ubuntu terminal.

Before installing swift “libpython2.7” and “libpython2.7-dev” are needed to get Swift running. Run the following code.

@maxivak
maxivak / _0__ssl_certbot_letsencrypt.md
Last active April 16, 2024 21:48
Let's encrypt SSL certificates using certbot in docker

Directories on host machine:

  • /data/certbot/letsencrypt

  • /data/certbot/www

  • Nginx server in docker container

docker run -d --name nginx \
@krzemienski
krzemienski / backup-github.sh
Created May 15, 2020 12:01 — forked from rodw/backup-github.sh
A simple script to backup an organization's GitHub repositories, wikis and issues.
#!/bin/bash
# A simple script to backup an organization's GitHub repositories.
# NOTE: if you have more than 100 repositories, you'll need to step thru the list of repos
# returned by GitHub one page at a time, as described at https://gist.github.com/darktim/5582423
GHBU_BACKUP_DIR=${GHBU_BACKUP_DIR-"github-backups"} # where to place the backup files
GHBU_ORG=${GHBU_ORG-"<CHANGE-ME>"} # the GitHub organization whose repos will be backed up
# (if you're backing up a user's repos instead, this should be your GitHub username)
GHBU_UNAME=${GHBU_UNAME-"<CHANGE-ME>"} # the username of a GitHub account (to use with the GitHub API)
@SalomonBrys
SalomonBrys / Stadia-ubuntu.md
Last active February 15, 2023 17:48
Stadia in Ubuntu

Stadia in Ubuntu

1. Install Chromium-vaapi & drivers

  • Add the chromium-vaapi dev repository:
    sudo add-apt-repository ppa:saiarcot895/chromium-beta
    sudo apt-get update
    
  • Install Chromium-vaapi:
@LeandroBarral
LeandroBarral / docker-compose.yml
Created May 1, 2020 15:04
Medium: Traefik 2 - Setup Reverse Proxy with Let's Encrypt and Cloudflare Support
version: '3'
services:
traefik-reverse-proxy:
container_name: traefik
image: traefik:v2.2.1
command:
- --api=true
- --api.dashboard=true
- --entrypoints.web.address=:80
@Andrey2G
Andrey2G / encoding.txt
Last active May 3, 2024 11:26
Video Encoding with multiple resolutions
ffmpeg -i "c:/videos/sample.mp4
-map 0:v:0 -map 0:a:0 -map 0:v:0 -map 0:a:0 -map 0:v:0 -map 0:a:0
-c:v libx264 -crf 22 -c:a aac -ar 48000
-filter:v:0 scale=w=480:h=360 -maxrate:v:0 600k -b:a:0 64k
-filter:v:1 scale=w=640:h=480 -maxrate:v:1 900k -b:a:1 128k
-filter:v:2 scale=w=1280:h=720 -maxrate:v:2 900k -b:a:2 128k
-var_stream_map "v:0,a:0,name:360p v:1,a:1,name:480p v:2,a:2,name:720p"
-preset slow -hls_list_size 0 -threads 0 -f hls -hls_playlist_type event -hls_time 3
-hls_flags independent_segments -master_pl_name "name-pl.m3u8"
"c:/videos/encoded/name-%v.m3u8"
@thebitbytebit
thebitbytebit / waifu2x_VMAF_measurement.sh
Created February 25, 2020 20:24
Waifu2x scaling up vs. Bilinear vs. Bicubic objective measurement
#!/bin/sh
## Christopher Kennedy Feb 2020
## Crunchyroll Waifu2x upscaling objective measurement
##
## Note you must install waifu2x and run this in the waifu2x directory,
## plus have an FFmpeg with VMAF enabled (must build from scratch)
##
## Dependencies:
## https://ffmpeg.org
@felipecsl
felipecsl / setup.sh
Last active August 25, 2022 23:06
Base EC2 instance setup for Amazon Linux box
# Install all the packages
sudo yum install -y \
curl gpg gcc gcc-c++ make git \
openssl-devel readline-devel libcurl-devel \
zlib-devel postgresql-server.x86_64 ruby-devel \
sqlite sqlite-devel ruby-rdoc python-devel \
cairo-devel libffi-devel python-pip nc docker \
tmux htop postgresql-libs postgresql-devel \
amazon-cloudwatch-agent
@mayneyao
mayneyao / notion2blog.js
Last active February 29, 2024 18:01
Notion.so > Personal Blog | custom domain + disqus comment
const MY_DOMAIN = "agodrich.com"
const START_PAGE = "https://www.notion.so/gatsby-starter-notion-2c5e3d685aa341088d4cd8daca52fcc2"
const DISQUS_SHORTNAME = "agodrich"
addEventListener('fetch', event => {
event.respondWith(fetchAndApply(event.request))
})
const corsHeaders = {
"Access-Control-Allow-Origin": "*",
@ShannonScott
ShannonScott / readme.md
Last active May 6, 2024 06:15
[Transcode h265] Use ffmpeg to transcode a video to h.265 / hvc1 which will play natively on a Mac (and Linux). #tags: video, python, ffmpeg