Skip to content

Instantly share code, notes, and snippets.

@kazuhisya
kazuhisya / find-dsstore
Created March 1, 2020 07:44
find-dsstore
#!/bin/sh
find . -name ".DS_Store" -print ; find . -name "._*" -print ;
echo "削除しますか? [Y/n]"
read ANSWER
ANSWER=`echo $ANSWER | tr y Y | tr -d '[\[\]]'`
#echo $ANSWER
case $ANSWER in
""|Y* ) find . -name ".DS_Store" -print -exec rm -r {} ";" ; find . -name "._*" -print -exec rm -r {} ";";;
* ) echo "exit";;
@kazuhisya
kazuhisya / unzip_jp
Created February 3, 2020 11:45
unzip_jp
#!/usr/bin/bash
unzip -Ocp932 $1
# vi: set ft=dockerfile :
FROM centos:7 AS build-env
WORKDIR /root
RUN yum install -y epel-release
RUN yum install -y golang openldap-devel make gettext git rpm-build
RUN git clone -b rpm https://github.com/kazuhisya/lb
RUN cd lb && make rpm
FROM centos:7
@kazuhisya
kazuhisya / albert.desktop
Created November 23, 2017 09:15
.config/autostart/albert.desktop
#!/usr/bin/env xdg-open
[Desktop Entry]
Categories=Utility;
Comment=A desktop agnostic launcher
Exec=env QT_SCALE_FACTOR=0.5 albert
GenericName=Albert
Icon=albert
Name=Albert
StartupNotify=false
Type=Application
@kazuhisya
kazuhisya / OSX-junos_pulse_listenToMe.sh
Created March 1, 2017 01:48 — forked from Andrewpk/OSX-junos_pulse_listenToMe.sh
wtf juniper. Anyone else find it irritating that junos pulse services and pulse tray must always running in OS X regardless of whether or not you're currently connected? Yeah, me too. I added the following as aliases to my shell to fix this problem. Be sure to change your /Library/LaunchAgents/net.juniper.pulsetray.plist file to reflect the `Kee…
#################################################################################
# start and stop the vpn from the command line from now on with these two commands
# or rename the aliases as you see fit.
#################################################################################
alias startvpn="sudo launchctl load -w /Library/LaunchDaemons/net.juniper.AccessService.plist; open -a '/Applications/Junos Pulse.app/Contents/Plugins/JamUI/PulseTray.app/Contents/MacOS/PulseTray'"
alias quitvpn="osascript -e 'tell application \"PulseTray.app\" to quit';sudo launchctl unload -w /Library/LaunchDaemons/net.juniper.AccessService.plist"
# vi: set ft=dockerfile :
FROM centos:7
ENV TZ="JST-9" \
SHEEP_VERSION="1.0.2_rc0"
# setting
RUN yum install -y epel-release && \
yum groupinstall -y --setopt=tsflags=nodocs "Base" "Development Tools" && \
yum install -y --setopt=tsflags=nodocs corosync corosynclib corosynclib-devel && \
# vi: set ft=dockerfile :
FROM centos:6
RUN yum install -y epel-release && \
yum groupinstall -y "Base" "Development Tools" && \
yum install -y --nogpgcheck http://ymu.dl.osdn.jp/linux-ha/66141/pacemaker-repo-1.1.14-1.1.el6.x86_64.rpm && \
yum install -y corosync corosynclib corosynclib-devel && \
yum install -y userspace-rcu userspace-rcu-devel yasm yasm-devel && \
yum install -y fuse fuse-devel && \
@kazuhisya
kazuhisya / keybase.md
Last active February 14, 2017 15:56
keybase.md

Keybase proof

I hereby claim:

  • I am kazuhisya on github.
  • I am kazuhisya (https://keybase.io/kazuhisya) on keybase.
  • I have a public key ASCVLUMPDNHPvIkuEAZ_10yCg750WOWiACn9Fyv9VTEr4Qo

To claim this, I am signing this object: