This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Check for the correct number of arguments | |
if [ "$#" -ne 1 ]; then | |
echo "Usage: $0 <video_filename>" | |
exit 1 | |
fi | |
VIDEO_FILE="$1" | |
DURATION=$(ffmpeg -i "$VIDEO_FILE" 2>&1 | grep Duration | awk '{print $2}' | tr -d , | awk -F: '{print $1*3600+$2*60+$3}') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- | |
https://play.tailwindcss.com/7Lezp1m7gx | |
--> | |
<div class="relative flex min-h-screen flex-col justify-center overflow-hidden bg-gray-50 px-6 py-6 font-serif antialiased sm:py-12"> | |
<img src="/img/beams.jpg" alt="" class="absolute top-1/2 left-1/2 max-w-none -translate-x-1/2 -translate-y-1/2" width="1308" /> | |
<div class="absolute inset-0 bg-[url(/img/grid.svg)] bg-center [mask-image:linear-gradient(180deg,white,rgba(255,255,255,0))]"></div> | |
<div class="relative flex min-w-full bg-white shadow-xl ring-1 ring-gray-900/5 sm:mx-auto sm:max-w-lg sm:rounded-lg"> | |
<div class="mx-auto grid w-full grid-cols-2"> | |
<div class="flex flex-col justify-center gap-6 lg:gap-24"> | |
<h1 class="mx-auto text-5xl font-bold lg:text-8xl">[Your Name]</h1> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ffmpeg -i "url.m3u8" -c copy -map 0 -reset_timestamps 1 -f segment -segment_time 10 -strftime 1 "%Y-%m-%d__%H:%M:%S.ts" | |
cat *.ts > all.ts | |
ffmpeg -i all.ts -c copy all.mp4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
========================================================================================================================================================================================================== | |
========================================================================================================================================================================================================== | |
========================================================================================================================================================================================================== | |
======================:::::::::=========================================================================================================================================================================== | |
========================================================================================================================================================================================================== | |
========= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
================================================================================ | |
================================================================================ | |
================================================================================ | |
================================================================================ | |
================================================================================ | |
=================================------------:================================== | |
==============================---:==========:---================================ | |
==============================---:===:--:===:---================================ | |
==============================---:====--====:---================================ | |
==============================----==========:---================================ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[GlobalSettings] | |
FileRootPath=\??\%SystemDrive%\Sandbox\%USER%\%SANDBOX% | |
SeparateUserFolders=y | |
KeyRootPath=\REGISTRY\USER\Sandbox_%USER%_%SANDBOX% | |
IpcRootPath=\Sandbox\%USER%\%SANDBOX%\Session_%SESSION% | |
NetworkEnableWFP=n | |
EditAdminOnly=y | |
ForceDisableAdminOnly=n | |
ForgetPassword=n | |
Template=WindowsRasMan |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import ctypes | |
def is_admin(): | |
try: | |
return ctypes.windll.shell32.IsUserAnAdmin() | |
except: | |
return False | |
if is_admin(): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const puppeteer = require('puppeteer'); | |
(async () => { | |
const browser = await puppeteer.launch({ | |
defaultViewport: null, | |
args:[ | |
'--no-sandbox', | |
'--ignore-certificate-errors', | |
'--window-size=1920,1080' | |
], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
When/If you run into the following when trying to install @vue/cli similar: | |
Maximum call stack size exceeded on npm install | |
Reinstall NPM: | |
https://github.com/brock/node-reinstall | |
Do perms if installed as root | |
https://stackoverflow.com/questions/51811564/sh-1-node-permission-denied |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt install -y apt-transport-https lsb-release ca-certificates | |
sudo wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg | |
sudo sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list' | |
sudo apt update | |
sudo apt-get install -y php7.3 php7.3-common | |
sudo apt-get install -y php7.3-curl php7.3-xml php7.3-zip php7.3-gd php7.3-mysql php7.3-mbstring php7.3-sqlite3 | |
sudo apt-get purge -y php7.0 php7.0-common |
NewerOlder