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/sh | |
record=$(pgrep -a ffmpeg | grep x11grab | awk "{print \$1}" | xargs -I {} echo {}) | |
if [ -z $record ]; | |
then | |
xwininfo | { | |
while IFS=: read -r k v; do | |
case "$k" in | |
*"Absolute upper-left X"*) x=$v;; | |
*"Absolute upper-left Y"*) y=$v;; | |
*"Border width"*) bw=$v ;; |
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
FROM docker.io/library/wordpress:6.0.2 | |
# See https://www.shellhacks.com/create-csr-openssl-without-prompt-non-interactive/ | |
RUN openssl req -new -newkey rsa:2048 -days 1095 -nodes -x509 -keyout /etc/ssl/private/wp.key -out /etc/ssl/private/wp.crt -subj "/C=ID/ST=Surabaya/L=Surabaya/O=ISTTS/OU=IT Department/CN=stts.edu" | |
RUN a2enmod ssl | |
COPY ./wp-ssl.conf /etc/apache2/sites-available/wp-ssl.conf | |
RUN a2ensite wp-ssl | |
EXPOSE 80 | |
EXPOSE 443 |
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 | |
DESKTOP=$(wmctrl -d | grep "*" | awk --field-separator=" " '{print $1}') | |
STATUS=$(wmctrl -l | grep " $DESKTOP " | grep -i gvim | wc -l) | |
WIN=$(wmctrl -l | grep " $DESKTOP " | grep -i gvim | awk '{print $4}') | |
# zenity --notification --text="$STATUS $DESKTOP $WIN" | |
if [ $STATUS -gt 0 ] | |
then | |
activeWindow=$(xprop -id $(xprop -root _NET_ACTIVE_WINDOW | cut -d ' ' -f 5) WM_NAME | cut -d '"' -f 2) |
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 | |
STATUS=$(ps -aux | grep share/spotify/spotify | grep -v grep | wc -l) | |
if [ $STATUS -gt 0 ] | |
then | |
activeWindow=$(xprop -id $(xprop -root _NET_ACTIVE_WINDOW | cut -d ' ' -f 5) WM_NAME | cut -d '"' -f 2) | |
if [[ $activeWindow =~ "Spotify" ]] | |
then | |
wmctrl -r "spotify" -b toggle,hidden |
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
; | |
; AutoHotkey Version: 1.x | |
; Language: English | |
; Platform: Win9x/NT | |
; Author: Jack Dunning <[email protected]> | |
; Author: Benyamin Limanto <[email protected]> | |
; | |
; Script Function: | |
; Create a menu for quick launching program shortcuts and links by categories (folders). | |
; Date: January 14, 2013 |
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 pyodbc | |
# Specifying the ODBC driver, server name, database, etc. directly | |
con = pyodbc.connect('DRIVER={SQL Server Native Client 10.0};SERVER=127.0.0.1;PORT=1433;DATABASE=coba;UID=sa;PWD=12345') | |
# Using a DSN, but providing a password as well | |
# cnxn = pyodbc.connect('DSN=test;PWD=password') | |
# Create a cursor from the connection | |
db = con.cursor() |
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
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. | |
; #Warn ; Enable warnings to assist with detecting common errors. | |
SendMode Input ; Recommended for new scripts due to its superior speed and reliability. | |
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory. | |
SetTitleMatchMode, 2 ; contain | |
; remap global Win+E jadi Win+1 | |
#e::#1 | |
;#z::#!s | |
; Calendar |
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
/*** Megabar Styler General - version 2020-07-27 ***/ | |
/*** General Preferences ***/ | |
:root { | |
/* Number of pixels of enlargement when URL bar is focused */ | |
--mbarstyler-popout-pixels: 0px; /* [0px - 7px] */ | |
/* Top Bar Display or Not */ | |
--mbarstyler-top-bar-display: block; /* [block,none] */ |
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
REGEDIT4 | |
[HKEY_CLASSES_ROOT\Folder\shell\VimHere] | |
@="Open with &Vim" | |
"Icon"="C:\\Apps\\vim\\gvim.exe,0" | |
[HKEY_CLASSES_ROOT\Folder\shell\VimHere\command] | |
@="\"C:\\Apps\\vim\\gvim.exe\" \"%1\"" | |
[HKEY_CLASSES_ROOT\Directory\shell\VimHere] | |
@="Open with &Vim" |
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
<html> | |
<head> | |
<link rel="stylesheet" type="text/css" href="style.css"> | |
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css"> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.16.0/umd/popper.min.js"></script> | |
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.4.1/js/bootstrap.min.js"></script> | |
</head> | |
<body> | |
<form method="post" action=""> |
NewerOlder