How to add Live Template in Webstorm
- open preferences
- editor> live templates
- add template group for React Native
- add templates below to the new group
- define context > javascript
- edit variables > add "fileNameWithoutExtension" to "$fnName$"
# A collection of snippets for managing Heroku env vars | |
# It ain't pretty but it works | |
# Copy Heroku config to a local .env file | |
heroku config --app $HEROKU_APP | sed 's/: */=/' | tail -n +2 | tee $ENV_FILE | |
# Set a Heroku app's config from a local env file | |
# I got this oneliner from a blog somewhere, can't find it again | |
heroku config:set --app $HEROKU_APP $(cat .env | sed '/^$/d; /#[[:print:]]*$/d') | |
# Set a Heroku app's config from another Heroku app's config |
/*<?php | |
//*/public class PhpJava { public static void main(String[] args) { System.out.printf("/*%s", | |
//\u000A\u002F\u002A | |
class PhpJava { | |
static function main() { | |
echo(//\u000A\u002A\u002F | |
"Hello World!"); | |
}} | |
//\u000A\u002F\u002A | |
PhpJava::main(); |
var express = require('express'); | |
var session = require('express-session'); | |
var RedisStore = require('connect-redis')(session); | |
var Strategy = require('./passport-openidconnect/index').Strategy; | |
module.exports.configure = function configure(app, passport) { | |
var identityServer = 'https://users.xxx.com/identity'; | |
var auth = { |