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 httpd:2.4 | |
COPY ./public-html/ /usr/local/apache2/htdocs/ | |
COPY ./server.crt /usr/local/apache2/conf/ | |
COPY ./server.key /usr/local/apache2/conf/ | |
RUN sed -i \ | |
-e 's/^#\(Include .*httpd-ssl.conf\)/\1/' \ | |
-e 's/^#\(LoadModule .*mod_ssl.so\)/\1/' \ | |
-e 's/^#\(LoadModule .*mod_socache_shmcb.so\)/\1/' \ | |
conf/httpd.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
FROM httpd:2.4 | |
COPY ./public-html/ /usr/local/apache2/htdocs/ | |
COPY ./server.crt /usr/local/apache2/conf/ | |
COPY ./server.key /usr/local/apache2/conf/ | |
RUN sed -i \ | |
-e 's/^#\(Include .*httpd-ssl.conf\)/\1/' \ | |
-e 's/^#\(LoadModule .*mod_ssl.so\)/\1/' \ | |
-e 's/^#\(LoadModule .*mod_socache_shmcb.so\)/\1/' \ | |
conf/httpd.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
const puppeteer = require('puppeteer'); | |
(async () => { | |
// ブラウザ起動 | |
const browser = await puppeteer.launch(); | |
const page = await browser.newPage(); | |
// ヤフーのページを開く | |
await page.goto('https://www.yahoo.co.jp/'); | |
// ヤフーページ内でニュースの一覧を取得する Javascript を実行する |
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 java.time.Duration; | |
class Hoge { | |
public static void main(String[] args) { | |
Duration d1 = Duration.ofSeconds(1); | |
System.out.println(d1.toMinutes()); | |
Duration d2 = Duration.ofSeconds(2); | |
System.out.println(d2.toMinutes()); |
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
var appPath = System.Reflection.Assembly.GetExecutingAssembly().Location; | |
var cert = new X509Certificate2(appPath); | |
X509Certificate2UI.DisplayCertificate(cert); |
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
public class SampleFormatDate { | |
public static void main( String[] args ) { | |
formatDate(); | |
} | |
public static void formatDate() { | |
Date d1 = Calendar.getInstance(Locale.JAPAN).getTime(); | |
// yyyy2013年2月7日木曜日 | |
SimpleDateFormat sdf = new SimpleDateFormat("'yyyy'yyyy年M月d日E曜日"); | |
System.out.println(sdf.format(d1)); |
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
describe 'テスト対象' do | |
context '状態' do | |
it '期待する出力' do | |
end | |
end | |
end |
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
Object.constants.sort.map { |e| | |
Object.const_get(e.to_s) | |
}.select { |e| | |
e.ancestors.include?(Exception) if e.class == Class | |
} |
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
def subscribe(*args, &block) | |
p args | |
p block | |
args << {} unless args.last.is_a?(Hash) | |
p args | |
args.last.update(:block => block) | |
p args | |
end |
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
2つ目 |
NewerOlder