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
- aaa | |
- <%= var1 %> | |
- ccc_<%= var2 %>: eee |
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
require 'erb' | |
require 'yaml' | |
# VARIABLE DEFINITION | |
var1 = 'bbb' | |
var2 = 'ddd' | |
# FORMAT TRANSLATION | |
yml_erb = ARGF.read() | |
ruby_data_type = ERB.new(yml_erb).result(binding) |
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
#!/usr/bin/env ruby | |
require 'csv' | |
require 'json' | |
require 'securerandom' | |
line = STDIN.gets.chomp | |
csv = CSV.new(line) | |
header = csv.to_a[0] |
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
#!/usr/bin/env ruby | |
=begin | |
Group Watcherで生成したCSVの開始日と開始時刻、 | |
および終了日と終了時刻を一列にまとめて、 | |
elasticsearchのdate型に合わせる。 | |
Group Watcherが生成するCSVのヘッダは次の通り。 | |
"開始日","開始時刻","終了日","終了時刻","件名", | |
"場所","公/非","分類","グループ名","ユーザー名", | |
"内容","アラーム オン/オフ","アラーム日付","アラーム時刻" |
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
#!/bin/bash | |
fname=$1 | |
cat ${fname} | while IFS= read line; do | |
if [ -n "${line}" ]; then | |
echo " ${line}" | |
else | |
echo " " | |
fi | |
done |
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
<!-- HTML Example --> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<script src="https://obniz.io/js/jquery-3.2.1.min.js"></script> | |
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" integrity="sha384-WskhaSGFgHYWDcbwN70/dfYBj47jz9qbsMId/iRN3ewGhXQFZCSftd1LZCfmhktB" crossorigin="anonymous"> | |
<script src="https://unpkg.com/obniz@latest/obniz.js"></script> | |
</head> | |
<body> |
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 Obniz = require("obniz"); | |
const express = require('@runkit/runkit/express-endpoint/1.0.0'); | |
const app = express(exports); | |
const yourObnizId = "OBNIZ_ID" // write your obniz id | |
app.get('/', async (req,res) =>{ | |
let obniz = new Obniz(yourObnizId); | |
let connected = await obniz.connectWait({timeout:10}); |
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
// See https://github.com/dialogflow/dialogflow-fulfillment-nodejs | |
// for Dialogflow fulfillment library docs, samples, and to report issues | |
'use strict'; | |
const functions = require('firebase-functions'); | |
const {WebhookClient} = require('dialogflow-fulfillment'); | |
const {Card, Suggestion} = require('dialogflow-fulfillment'); | |
const request = require('request'); |
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
<!-- HTML Example --> | |
<html> | |
<head> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<script src="https://obniz.io/js/jquery-3.2.1.min.js"></script> | |
<script src="https://unpkg.com/obniz@latest/obniz.js"></script> | |
</head> | |
<body> | |
<div id="obniz-debug"></div> |
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
<!-- HTML Example --> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<script src="https://obniz.io/js/jquery-3.2.1.min.js"></script> | |
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" integrity="sha384-WskhaSGFgHYWDcbwN70/dfYBj47jz9qbsMId/iRN3ewGhXQFZCSftd1LZCfmhktB" crossorigin="anonymous"> | |
<script src="https://unpkg.com/obniz@1.9.3/obniz.js" crossorigin="anonymous"></script> | |
</head> | |
<body> |
OlderNewer