Skip to content

Instantly share code, notes, and snippets.

@unak
unak / ruby-mswin64-202204.md
Last active November 11, 2023 06:45
RubyをVisual C++でビルドする 2022.04版(+2022.12・2023.06追記)

Visual C++をインストールする

というか、Visual Studioになるわけだが。 普通はCommunity Editionで問題ないと思うが、用途に応じてライセンスを選ぶこと。 インストールする際には、Windowsデスクトップ開発とかいうのを選ぶ。他はお好みで。 あー、確認してないけど、英語の言語パックは入れた方が多分いいです。入れないとだめかもしれない(thx hsbtさん)。

vcpkgをインストールする

GitHubにあるので、READMEの手順に従えばいい。 この過程でgitも入ることになる。

#!/bin/bash -ex
command -v gs > /dev/null || {
echo "gs(ghostscript) is not found">&2
exit 1
}
command -v curl > /dev/null || {
echo "curl is not found">&2
exit 1
function Add-EnvPath {
param(
[Parameter(Mandatory=$true)]
[string] $Path,
[ValidateSet('Machine', 'User', 'Session')]
[string] $Container = 'Session'
)
if ($Container -ne 'Session') {
git config --global alias.his "log --pretty='format:%C(yellow)%h%Creset %C(magenta)%<(22,trunc)%cd%Creset %><(11,trunc)%C(black bold)%ar%Creset | %Cgreen%<(10)%an%Creset | %<(130,trunc)%s %Cred%<(45,trunc)%d%Creset' --date=iso --all -n 15"
@Gab-km
Gab-km / github-flow.ja.md
Last active March 21, 2025 03:38 — forked from juno/github-flow.ja.md
GitHub Flow (Japanese translation)
@rummelonp
rummelonp / 0-oppai.md
Created February 29, 2012 03:14
いかにしておっぱい画像をダウンロードするか〜2012 for Ruby
@yoggy
yoggy / ldr2pin.rb
Created January 12, 2011 06:19
Livedoor ReaderのPinをまとめてpinboard.inにブックマークするスクリプト
#!/usr/bin/ruby
#
# ldr2pin.rb - Livedoor ReaderのPinをまとめてpinboard.inにブックマークするスクリプト
#
$KCODE='utf8'
require 'rubygems'
require 'net/netrc'
require 'mechanize'
# Clojure syntax highlighting for GNU source-highlight
# rocks with SHJS
# http://gist.github.com/265810
comment start ";"
include "number.lang"
vardef SPECIALCHAR = '\\.'