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
mysql -uuser -p -e "show tables in ターゲットのDB名" | tail --lines=+2 | xargs -i echo "ALTER TABLE {} ENGINE=INNODB;" > alter_table.sql |
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
if [ ${DRY_RUN} = "true" ]; then | |
sudo rsync -avnz --delete -e ssh ${SOURCE_SERVER}:/{$SOURCE_DIR}/ {$BACKUP_DIR} | |
else | |
sudo rsync -avz --delete -e ssh ${SOURCE_SERVER}:/{$SOURCE_DIR}/ {$BACKUP_DIR} | |
fi |
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 | |
USAGE="usage: $0 [REDMINE_URL] [PROJECT_ID] [API_KEY]" | |
if [ $# -lt 3 ]; then | |
echo >&2 $USAGE | |
exit 1 | |
fi | |
REDMINE_URL=$1 |
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
<a class="icon icon-reload" href="#" | |
title="Revert" id="revert_template" onclick="revertAppliedTemplate();"> | |
Revert | |
</a> | |
<script> | |
function revertAppliedTemplate() { | |
$('#revert_template').toggleClass('disabled'); | |
} | |
</script> |
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 centos:7 | |
MAINTAINER Tatsuya Saito <twopackas@gmail.com> | |
RUN yum -y update && \ | |
yum install -y epel-release && \ | |
yum-config-manager --enable epel | |
RUN rm -f /etc/rpm/macros.image-language-conf && \ | |
sed -i '/^override_install_langs=/d' /etc/yum.conf && \ |
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
# coding: utf-8 | |
import pprint | |
import os # 環境変数を扱うモジュール | |
import sys # コマンドライン引数を扱うモジュール | |
import requests # http通信に便利なモジュール | |
# | |
# $ python --version | |
# Python 3.5.4 | |
# |
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 requests | |
import json | |
import os | |
import textwrap | |
from datetime import datetime | |
from datetime import timedelta | |
import re | |
class ConfluencePagePost: | |
'''Class to post page/blog content to Confluence via REST API.''' |
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
require_dependency "full_text_search/hooks/search_index_options_content_bottom_hook" | |
require_dependency "full_text_search/hooks/issues_show_description_bottom_hook" | |
require_dependency "full_text_search/hooks/similar_issues_helper" | |
# これも追加? | |
require_dependency "full_text_search/hooks/search_helper" | |
require "full_text_search/searcher" | |
Redmine::Plugin.register :full_text_search do |
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
$ python sample.py | |
Hello World! |
OlderNewer