Skip to content

Instantly share code, notes, and snippets.

View aminya's full-sized avatar
🤖

Amin Yahyaabadi aminya

🤖
View GitHub Profile
@aminya
aminya / batch_audio_replace.ps1
Created November 15, 2021 20:00
Batch replace audio in video files
# This uses ffmpeg https://www.ffmpeg.org/
# modify the video and audio extensions if needed
mkdir -p output
foreach ($video in (ls *.mp4)) {
$video_name = ($video).Name;
$audio_name = $video_name.replace('.mp4', '.mp3');
ffmpeg -i $video_name -i $audio_name -c copy -map 0:v:0 -map 1:a:0 "output/$video_name"
; Download Autohotkey from https://www.autohotkey.com/download/ to use this
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Event ; Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
; copy - F3
F3::^c
using Faker
function genstring(num)
list=Vector{String}(undef, num)
for i=1:num
list[i]= Faker.lexify("???????")
end
return list
end
# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
# editor.onDidSave ->
@aminya
aminya / PrettyTableHTML.jl
Last active February 4, 2020 20:20
PrettyTable+AcuteML
using AcuteML, PrettyTables
@aml mutable struct PrettyTable "table"
style::String, "~"
body::String,"~"
end
@aml mutable struct Doc "html"
table::PrettyTable, "table"
end