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
func columnIndexFromGenericToSpreadsheet(columnIndex int) (string, error) { | |
return columnIndexFromGenericToSpreadsheetImpl(columnIndex, "ABCDEFGHIJKLMNOPQRSTUVWXYZ") | |
} | |
func columnIndexFromGenericToSpreadsheetImpl(columnIndex int, spreadsheetColumnIndexList string) (string, error) { | |
var ( | |
genericColumnIndex = "" | |
listLength = len(spreadsheetColumnIndexList) | |
) |
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 { takeEvery, delay } from 'redux-saga'; | |
import { put, call } from 'redux-saga/effects'; | |
import { increment } from './actions'; | |
export function* incrementAsync() { | |
yield call(delay, 1000); | |
yield put(increment()); | |
} | |
export default function* rootSaga() { |
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 { createAction } from 'redux-actions'; | |
export const increment = createAction('increment'); |
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
'use strict'; | |
const Dispatcher = require('./Dispatcher'); | |
class CounterActions extends Dispatcher.Actions { | |
submitClicked (text) { | |
this.emit('submit', text); | |
} |
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 (!([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole(` | |
[Security.Principal.WindowsBuiltInRole] "Administrator")) { | |
Write-Warning "管理者として実行してください" | |
exit 1 | |
} | |
echo "Windowsの開発環境を構築します" | |
echo "" |
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
private Mesh CreateBlockMesh(GameObject cc, Vector3 centerPos) { | |
Vector3[] v = new Vector3[4]; | |
/********** | |
* 表面 | |
* ********/ | |
int[] use_vertices1 = new int[4]; | |
v[0] = centerPos + Vector3.up * 0.5f + Vector3.right * 0.5f; | |
v[1] = centerPos + Vector3.up * 0.5f + Vector3.left * 0.5f; | |
v[2] = centerPos + Vector3.down * 0.5f + Vector3.left * 0.5f; |
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
function onSubmitForm(e){ | |
var res = e.response; | |
var FORM_DATA = res.getItemResponses(); | |
var item = FORM_DATA[0].getResponse(); // 支出項目 | |
var summary = FORM_DATA[1].getResponse() // 支出概要 | |
var money = FORM_DATA[2].getResponse(); // 支出金額 | |
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 insert_message | |
img_file = "描画対象のファイルパス" | |
FileUtils.cp(img_file, img_file + ".org", {:preserve => true}) # 元画像退避 | |
img = Magick::ImageList.new(img_file) # 画像オブジェクト | |
draw = Magick::Draw.new # 描画オブジェクト | |
begin | |
draw.annotate(img, 0, 0, 0, -175, message) do | |
self.font = 'やさしさゴシックのファイルパス' # フォント | |
self.fill = 'black' # 文字色 |
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
using UnityEngine; | |
using System.Collections.Generic; | |
[ExecuteInEditMode] | |
[RequireComponent(typeof(MeshRenderer))] | |
[RequireComponent(typeof(MeshFilter))] | |
public class GenerateMesh : MonoBehaviour | |
{ | |
/// <summary> | |
/// パス座標 |
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
using UnityEngine; | |
public class SingletonMonoBehaviour<T> : MonoBehaviour where T : SingletonMonoBehaviour<T> | |
{ | |
protected static T instance; | |
/// <summary> | |
/// インスタンスの取得 | |
/// </summary> | |
public static T Instance { |
NewerOlder