This file contains hidden or 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
#!/usr/bin/env bash | |
# | |
# adduser.sh | |
# | |
# usage: curl -fsSL $URL | bash -s -- <github-user-name> [<user-name>] | |
# | |
set -eux -o pipefail | |
main() { | |
local github="$1" |
This file contains hidden or 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 'dart:math' as math; | |
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(const MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
const MyApp({Key? key}) : super(key: key); |
This file contains hidden or 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
package main | |
import "fmt" | |
func main() { | |
a := [5]int{} | |
b := a[:] | |
fmt.Println(b) | |
} |
This file contains hidden or 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
// +build tools | |
package tools | |
import ( | |
_ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-grpc-gateway" | |
_ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2" | |
_ "google.golang.org/grpc/cmd/protoc-gen-go-grpc" | |
_ "google.golang.org/protobuf/cmd/protoc-gen-go" | |
) |
This file contains hidden or 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
#!/usr/bin/env sh | |
GOLANG_IMAGE="golang:1.14.4-alpine3.12" | |
cat <<EOF | docker run -i --rm -v ${PWD}:/build ${GOLANG_IMAGE} sh | |
apk add --no-cache gcc musl-dev git | |
git clone --shallow-since=2020/06/07 https://github.com/cosmos72/gomacro.git /go/src/github.com/cosmos72/gomacro | |
cd /go/src/github.com/cosmos72/gomacro | |
git checkout 647446f | |
env CGO_ENABLED=1 go install -tags netgo -installsuffix netgo --ldflags '-extldflags "-static"' |
This file contains hidden or 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
#include <type_traits> | |
namespace sfinae { | |
template<bool b> using where = typename std::enable_if<b, std::nullptr_t>::type; | |
template<class A, class = std::nullptr_t> | |
struct case_t { | |
static char const* label() { return "cond-default"; } | |
}; |
This file contains hidden or 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/bash | |
WORK=$PWD | |
main() { | |
trap "exit 1" SIGINT | |
msg "git subtreeを実際に動かして学ぶための教材。" \ | |
"適当なところに pause を仕掛けて" \ | |
"ディレクトリ構造やgitの状態を覗き見して" \ |
This file contains hidden or 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/bash | |
# | |
# CMake Build Tool | |
# | |
# Copyright (c) 2015 takumakei | |
# | |
# This software is released under the MIT License. | |
# http://opensource.org/licenses/mit-license.php | |
# | |
# $Id: a58f8ef02f7aa5084af21a933965ec23fd75e60a $ |
This file contains hidden or 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
#!/usr/bin/env python | |
# coding: utf-8 | |
# | |
# Copyright (c) 2015 TAKUMA Kei | |
# | |
# This software is released under the MIT License. | |
# http://opensource.org/licenses/mit-license.php | |
# | |
# | |
# HOW TO USE THIS SCRIPT: |
This file contains hidden or 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
// Copyright (C) 2011 RiSK (sscrisk) | |
// | |
// Distributed under the Boost Software License, Version 1.0. (See | |
// accompanying file LICENSE_1_0.txt or copy at | |
// http://www.boost.org/LICENSE_1_0.txt) | |
#if !defined(SSCRISK_DEMANGLE_HPP) | |
#define SSCRISK_DEMANGLE_HPP | |
#if defined(_MSC_VER) && _MSC_VER >= 1020 | |
#pragma once |
NewerOlder