Skip to content

Instantly share code, notes, and snippets.

View masaru-b-cl's full-sized avatar

TAKANO Sho / @masaru_b_cl masaru-b-cl

View GitHub Profile
@masaru-b-cl
masaru-b-cl / Program.cs
Created February 27, 2014 07:57
single semicolon FizzBuzz
class Program
{
static void Main(string[] args)
{
System.Linq.Enumerable.ToList(
System.Linq.Enumerable.Select(
System.Linq.Enumerable.Range(1, 100)
, n =>
n % 3 == 0 && n % 5 == 0 ? "FizzBuzz" :
n % 3 == 0 ? "Fizz" :
@masaru-b-cl
masaru-b-cl / Program.cs
Created February 27, 2014 08:04
semicolonless FizzBuzz
class Program
{
static void Main(string[] args)
{
if (
System.Linq.Enumerable.ToList(
System.Linq.Enumerable.Select(
System.Linq.Enumerable.Range(1, 100),
n =>
n % 3 == 0 && n % 5 == 0 ? "FizzBuzz" :
Mar 11, 2014 3:28:26 PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/gitbucket] appears to have started a thread named [Generate Seed] but has failed to stop it. This is very likely to create a memory leak.
Mar 11, 2014 3:32:05 PM org.apache.catalina.core.StandardContext startInternal
SEVERE: Error listenerStart
Mar 11, 2014 3:32:05 PM org.apache.catalina.core.StandardContext startInternal
SEVERE: Context [/gitbucket] startup failed due to previous errors
Mar 11, 2014 3:32:05 PM org.apache.catalina.loader.WebappClassLoader clearReferencesJdbc
SEVERE: The web application [/gitbucket] registered the JDBC driver [org.h2.Driver] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver has been forcibly unregistered.
@masaru-b-cl
masaru-b-cl / fxcop.bat
Created March 24, 2014 01:32
execute FxCop from command line bat file.
@rem quoted path to FxCopCmd.exe.
set FXCOP_PATH="%ProgramFiles%\Microsoft Fxcop 10.0\FxCopCmd.exe"
@rem path to "FxCop Project File" that created by FxCop GUI (FxCop.exe).
set FXCOP_PROJ=MyProj.FxCop
@rem path to FxCop report file.
set FXCOP_REPORT=FxCopReport.xml
cd "%~d0%~p0"
@masaru-b-cl
masaru-b-cl / git-set-gitbucket-user
Created March 28, 2014 08:10
GitBucket向けにgit config実行するアレ
#!/bin/sh
git config user.name gbname
git config user.email gbname@example.com
#Mon Mar 31 10:33:43 JST 2014
gravatar=true
ldap.bind_password=password
notification=false
ldap.baseDN=dc\=example,dc\=co,dc\=jp
ldap_authentication=true
ssh=true
ldap.username_attribute=sAMAccountName
allow_account_registration=false
ldap.host=192.168.0.27
@masaru-b-cl
masaru-b-cl / gist:9886892
Created March 31, 2014 07:10
git clone from SSH error messages
$ git clone ssh://takano-s@servername.example.co.jp:22/takano-s/my-repos.git my-repos
Cloning into 'my-repos'...
takano-s@servername.example.co.jp's password:
bash: git-upload-pack: command not found
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
@masaru-b-cl
masaru-b-cl / Program.cs
Created April 14, 2014 05:27
メソッドチェーンの先頭で無名関数定義?
using System;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
var result = new Func<int, int>(x => x * x)
.Invoke(2)
@masaru-b-cl
masaru-b-cl / .gitignore
Created April 14, 2014 13:13
BOM付UTF-8な.gitignore
bin/
obj/
*.suo
*.user
TestResults/
@masaru-b-cl
masaru-b-cl / gist:697a95cc39c48226e1fe
Created May 16, 2014 09:01
OracleXE 11gでキャラセットをSJISにする手順
参考:Oracle 11g Express 文字コードを変更する : リード開発メモ
​http://freed411.doorblog.jp/archives/30018740.html
最後にユーザー表領域作成
CREATE TABLESPACE USERS
DATAFILE 'C:\oraclexe\app\oracle\oradata\XE\USERS.dbf'
size 1024M autoextend on maxsize 4096M
extent management local
segment space management auto;