List of helpful shortcuts for faster coding
If you have any other helpful shortcuts, feel free to add in the comments of this gist :)
DROP TABLE ticks CASCADE; | |
DROP TABLE ohlc_1s CASCADE; | |
CREATE TABLE ticks ( time TIMESTAMP NOT NULL, symbol varchar, price decimal, volume int); | |
CREATE TABLE ohlc_1s ( time TIMESTAMP NOT NULL, symbol varchar, o decimal, h decimal, l decimal, c decimal, v int); | |
SELECT create_hypertable('ticks', 'time'); | |
SELECT create_hypertable('ohlc_1s', 'time'); | |
CREATE OR REPLACE FUNCTION feed_ohlc_1s() RETURNS trigger AS | |
$BODY$ | |
DECLARE |
Thanks to the original blog post: https://equimper.com/blog/how-to-setup-tailwindcss-in-phoenix-1.4
cd assets
npm i --save-dev tailwindcss postcss-loader postcss-import
require 'bundler/inline' | |
gemfile do | |
source 'https://rubygems.org' | |
gem 'colorize' | |
end | |
class MatcherInterface | |
def initialize(some_object) | |
@some_object = some_object |
comment = "# frozen_string_literal: true\n" | |
filemode = "r+" | |
dirs = Dir[Rails.root.join('spec/**/*.rb').to_s] + Dir[Rails.root.join('lib/**/*.rake').to_s] + Dir[Rails.root.join('lib/**/*.rb').to_s] | |
dirs.each do |filename| | |
contents = File.open(filename, "r") do |f| | |
f.read | |
end | |
contents = comment + contents |
File | Purpose |
---|---|
/etc/compose/docker-compose.yml |
Compose file describing what to deploy |
/etc/systemd/system/docker-compose-reload.service |
Executing unit to trigger reload on docker-compose.service |
/etc/systemd/system/docker-compose-reload.timer |
Timer unit to plan the reloads |
/etc/systemd/system/docker-compose.service |
Service unit to start and manage docker compose |
# https://flukeout.github.io/ # | |
01. plate | |
02. bento | |
03. #fancy | |
04. plate apple | |
05. #fancy pickle | |
06. .small | |
07. orange.small | |
08. bento orange.small |
You're taking your first steps into Ruby
A good introduction to programming in general. Easy on newer programmers.
A short guide for getting you started into the magical world of OSS.
Are you a musician? Look for musical tools. Are you an artist? Look for some graphics libraries. Find something that works with your other passions to get you going.
If your passion is programming, look for ways to improve the environment.