Skip to content

Instantly share code, notes, and snippets.

@SteveClement
SteveClement / install_ffmpeg_libfdkaac.sh
Last active August 6, 2020 10:05 — forked from rafaelbiriba/install_ffmpeg_libfdkaac.sh
Install FFmpeg with libfdk_aac support (For Ubuntu)
# Criando um script .sh para executar todos os comandos
#user@servidor:~$ wget https://gist.githubusercontent.com/SteveClement/26d9c9035c635fb7bff05ff8eacd1a94/raw/d3a82be86039f72f25f8d2b8cbc6d5299be75cac/install_ffmpeg_libfdkaac.sh
#user@servidor:~$ chmod +x install_ffmpeg_libfdkaac.sh
#user@servidor:~$ ./install_ffmpeg_libfdkaac.sh
YOLO="true" # Living on the bleeding edge
x265="true" # Include libx265
mkdir -p ~/bin
@SteveClement
SteveClement / explode.sh
Created April 16, 2020 05:45
Explode video file with ffmpeg
#!/usr/bin/env bash
INPUT_FILE="${1}"
if [[ ! -f "${1}" ]]; then
echo "File "${1}" does not exist"
exit -1
fi
if [[ ${INPUT_FILE} == *"/"* ]]; then
echo "Slash exists"
@SteveClement
SteveClement / pullMergePush.sh
Created November 15, 2019 01:01
pull, merge and push my MISP branches
#!/usr/bin/env bash
BASE="2.4"
CURRENT_BRANCH=$(git branch | grep ^\* |cut -f 2 -d\ )
git checkout $BASE && git fetch upstream
git merge upstream/$BASE && git push
# gh-pages (not needed, will be done during doc regen)
@SteveClement
SteveClement / jsonschema
Created November 29, 2018 04:52
jsonschema script in case it is missing
#!/usr/bin/python3
# -*- coding: utf-8 -*-
import re
import sys
from jsonschema.cli import main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys.argv[0])
########### Checking Requirements ###########
[OK] Docker is Installed. Output: Docker version 18.06.1-ce, build e68fc7a
[OK] Git is Installed. Output: git version 2.19.1
[OK] Check: https://misp.dcso.de
Result: * Connected to misp.dcso.de (185.183.127.100) port 443 (#0).
[OK] Check: https://dockerhub.dcso.de/v2/
Result: * Connected to dockerhub.dcso.de (217.110.69.251) port 443 (#0).
[OK] Check: https://github.com/DCSO/misp-dockerized
Result: * Connected to github.com (192.30.255.113) port 443 (#0).
@SteveClement
SteveClement / twotwo-wayland.sh
Last active February 28, 2024 10:08 — forked from bhundven/nineteen-wayland.sh
Enlightenment 22 build script for Ubuntu/Debian with Wayland support.
#!/bin/bash
# vi: ts=4:sw=4:et
#
# twotwo.sh
# This script allows you to install/update Enlightenment 22 git version on
# Ubuntu 18.04 or Debian buster (testing), or remove E22 git from your system.
# ********************************************************************
# * This version builds enlightenment with wayland. *
# * That means this requires a very recent Ubuntu or Debian version. *
# * This may not work properly! You've been warned! *
@SteveClement
SteveClement / twotwo.sh
Last active November 22, 2020 06:49 — forked from bhundven/nineteen.sh
Enlightenment 22 build script for Ubuntu/Debian
#!/bin/bash
# vi: ts=4:sw=4:et
#
# twotwo.sh
# This script allows you to install/update Enlightenment 22 git version on
# Ubuntu 18.04 LTS or Debian testing (buster), or remove E22 git from your system.
# Originally from: http://ubuntuforums.org/showthread.php?t=2203190
# By: Philippe J. Guillaumie (batden AT sfr DOT fr).
# Additional updates by: Bryan Hundven (bryanhundven AT gmail DOT com).
#
@SteveClement
SteveClement / imageEffect.pde
Created January 26, 2018 16:20
Processing examples
PImage kitten;
void setup() {
size(2024, 512);
kitten = loadImage("kitten.jpg");
//kitten.filter(GRAY);
image(kitten, 0, 0);
}
void draw() {
#!/usr/bin/env python3
# Source: # https://github.com/arvydas/blinkstick-python/wiki/Example:-Display-Internet-connectivity-status
import socket
import time
try:
import netifaces
gws = netifaces.gateways()
@SteveClement
SteveClement / convert_mysql_to_sqlite3.sh
Last active January 26, 2020 09:26 — forked from grfiv/convert_mysql_to_sqlite3.sh
convert a mysql database to sqlite3
#!/usr/bin/env bash
#
# convert a mysql database to sqlite3
#
#see https://stackoverflow.com/questions/5164033/
# export-a-mysql-database-to-sqlite-database
mysql_host=localhost
mysql_user=george
#mysql_passwd=****************