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
| # Dashboard | |
| The dashboard is a grid of configurable **widgets** rendered on the IDE home view. It is authored visually (drag/resize/configure in edit mode) and persisted as a `.dashboard` YAML file in the user's Drive. Everything is local-first: edits update the IndexedDB cache and are reflected to Drive via the normal Push flow. | |
| > Implementation lives under `app/dashboard/`. The Japanese mirror of this doc is `dashboard_ja.md`. | |
| ## File format & storage | |
| - A dashboard is a YAML file with the `.dashboard` extension. | |
| - New dashboards are stored at `dashboards/{name}.dashboard`. A legacy single dashboard may exist at the root as `home.dashboard`. |
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
| const https = require('https'); | |
| const postSlack = (rec)=>{ | |
| return new Promise((resolve, reject)=>{ | |
| const path = rec.ecs_cluster.match(/staging/) ? process.env.STAGING_SLACK_PATH : process.env.PRODUCTION_SLACK_PATH; | |
| const data = JSON.stringify({ text: JSON.stringify(rec) }); | |
| const options = { | |
| hostname: 'hooks.slack.com', | |
| port: 443, | |
| path, |
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
| /* | |
| For processing data sent to Firehose by Cloudwatch Logs subscription filters. | |
| Cloudwatch Logs sends to Firehose records that look like this: | |
| { | |
| "messageType": "DATA_MESSAGE", | |
| "owner": "123456789012", | |
| "logGroup": "log_group_name", | |
| "logStream": "log_stream_name", |
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
| /* | |
| For processing data sent to Firehose by Cloudwatch Logs subscription filters. | |
| Cloudwatch Logs sends to Firehose records that look like this: | |
| { | |
| "messageType": "DATA_MESSAGE", | |
| "owner": "123456789012", | |
| "logGroup": "log_group_name", | |
| "logStream": "log_stream_name", |
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 { Actions, AppState } from "./reducers/index"; | |
| import { useReducer, useMemo, useRef, useEffect } from "react"; | |
| import withPromise from "./withPromise"; | |
| const groupStart = | |
| process.env.NODE_ENV !== "production" | |
| ? (val: string) => { | |
| console.groupCollapsed("Action Type:", val); | |
| } | |
| : (val: string) => {}; |
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/ruby | |
| if ARGV.length != 1 | |
| puts "#{$0} outputfile" | |
| exit -1 | |
| end | |
| unless file = File.open(ARGV[0],"wb") | |
| puts "#{$0} outputfile" | |
| puts "#{ARGV[0]} can't write" | |
| exit -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
| { | |
| "editor.minimap.enabled": false, | |
| "editor.formatOnSave": true, | |
| "tslint.alwaysShowRuleFailuresAsWarnings": true, | |
| "window.zoomLevel": 2, | |
| "explorer.confirmDelete": false, | |
| "files.trimTrailingWhitespace": true, | |
| "files.eol": "\n", | |
| "typescript.updateImportsOnFileMove.enabled": "always" | |
| } |
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
| function! <SID>StripTrailingWhitespaces() | |
| let l = line(".") | |
| let c = col(".") | |
| %s/\s\+$//e | |
| call cursor(l, c) | |
| endfun | |
| autocmd BufWritePre *.ts,*.rb,*.tsx,*.js,*.erb :call <SID>StripTrailingWhitespaces() |
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 ruby | |
| require 'nkf' | |
| raw = File.read("#{ENV['HOME']}/Downloads/EIJIRO-1445.TXT") | |
| data = NKF.nkf("-w -d", raw) | |
| results = {} | |
| first_flg = false | |
| data.each_line do |raw_line| | |
| next if !first_flg && !raw_line.match(/a\s+{不-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
| #!/usr/bin/ruby | |
| require 'rubygems' | |
| require 'mysql' | |
| require 'optparse' | |
| options = { | |
| :database => '', | |
| :host=> 'localhost', | |
| :create=> false, | |
| :count=> false, | |
| :index=> false, |
NewerOlder