Skip to content

Instantly share code, notes, and snippets.

@popq
popq / userDefineLang_Apache2.xml
Created December 18, 2019 15:03
httpd.conf syntax highlightning for Notepad++
<NotepadPlus>
<UserLang name="Apache" ext="conf htaccess">
<Settings>
<Global caseIgnored="no" />
<TreatAsSymbol comment="no" commentLine="yes" />
<Prefix words1="no" words2="no" words3="no" words4="no" />
</Settings>
<KeywordLists>
<Keywords name="Delimiters">&quot;00&quot;00</Keywords>
<Keywords name="Folder+">&lt;Directory &lt;DirectoryMatch &lt;Files &lt;FilesMatch &lt;IfDefine &lt;IfModule &lt;IfVersion &lt;Limit &lt;LimitExcept &lt;Location &lt;LocationMatch &lt;Proxy &lt;ProxyMatch &lt;VirtualHost</Keywords>

Keybase proof

I hereby claim:

  • I am popq on github.
  • I am popq (https://keybase.io/popq) on keybase.
  • I have a public key whose fingerprint is 37F2 E26A FE70 BC77 3CA4 6B67 9940 AA91 0EEB 5A07

To claim this, I am signing this object:

@popq
popq / Adding english subtitles to mp4 for iPad
Last active August 29, 2015 13:58
Useful command line hacks
MP4Box -add subtitle.srt:lang=eng:layout=0x60x0x-1:group=2:hdlr="sbtl:tx3g" movie.mp4
# Looping over a directory of similarily named movies and subtitle files, equal
# length of each filename.
# Adjust the cut -c for your setup
for i in `ls -l *.mp4 | cut -c 51-80`; do /Applications/Osmo4.app/Contents/MacOS/MP4Box -add $i.srt:lang=eng:layout=0x60x0x-1:group=2:hdlr="sbtl:tx3g" $i.mp4; done
# Looping as above, for filenames of different length, with no dots in filename before .mp4.
# Adjust cut -c for your setup.
for i in `ls -l *.mp4 | cut -c 51- | cut -f 1 -d.`; do /Applications/Osmo4.app/Contents/MacOS/MP4Box -add $i.srt:lang=eng:layout=0x60x0x-1:group=2:hdlr="sbtl:tx3g" $i.mp4; done