Based on https://docs.docker.com/compose/rails/
FROM ruby:2.5.1
RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs
RUN mkdir /site
| (async function generateReplies(document) { | |
| // https://conventionalcomments.org/#labels | |
| const LABEL = { | |
| praise: "praise", | |
| nitpick: "nitpick", | |
| suggestion: "suggestion", | |
| issue: "issue", | |
| todo: "todo", | |
| question: "question", | |
| thought: "thought", |
| import { array, object, number, string, date, InferType } from "yup"; | |
| import { Model } from "objection"; | |
| // Shared | |
| // Shared API data schema (objects shared between client and server) | |
| export const sharedSchema = object({ | |
| // none of these are required since not set until save (but they are also not nullable) | |
| id: number() | |
| .integer() | |
| .notRequired(), |
| version: "3.3" | |
| services: | |
| ################################################ | |
| #### Traefik Proxy Setup ##### | |
| ############################################### | |
| traefik: | |
| image: traefik:v2.0 | |
| restart: always |
| export default class StyleGroup { | |
| constructor(styles) { | |
| this.styles = styles; | |
| this.name = ''; // must set at runtime | |
| } | |
| } |
| sudo apt-get update | |
| sudo apt-get -y upgrade | |
| sudo apt-get install python3-setuptools | |
| sudo easy_install3 pip | |
| pip -V | |
| #pip 9.0.1 from /usr/local/lib/python3.5/dist-packages/pip-9.0.1-py3.5.egg (python 3.5) | |
| sudo chown -R username:username ~/.local/ | |
| # add to ./*shrc |
Based on https://docs.docker.com/compose/rails/
FROM ruby:2.5.1
RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs
RUN mkdir /site
Here are the simple steps needed to create a deployment from your local GIT repository to a server based on this in-depth tutorial.
You are developing in a working-copy on your local machine, lets say on the master branch. Most of the time, people would push code to a remote server like github.com or gitlab.com and pull or export it to a production server. Or you use a service like deepl.io to act upon a Web-Hook that's triggered that service.
| function largestBinaryGap(num) { | |
| var bin = Math.abs(num).toString(2), | |
| finalMax = 0, | |
| currentMax; | |
| for (var i = 0; i < bin.length; i++) { | |
| currentMax = 0; | |
| while (bin[i] === "0") { | |
| ++currentMax && ++i; | |
| } |
Picking the right architecture = Picking the right battles + Managing trade-offs
| var gulp = require('gulp'); | |
| var babel = require("gulp-babel"); | |
| var sourcemaps = require('gulp-sourcemaps'); | |
| var concat = require('gulp-concat'); | |
| var uglify = require('gulp-uglify'); | |
| gulp.task('default', () => { | |
| return gulp.src('js/main.js') | |
| .pipe(sourcemaps.init()) | |
| .pipe(babel({ |