Skip to content

Instantly share code, notes, and snippets.

View leo424y's full-sized avatar

Fly Chang leo424y

View GitHub Profile
@leo424y
leo424y / slider.html
Created July 16, 2021 09:15 — forked from DavidColby/slider.html
Implementation of a horizontal slider component with Stimulus and Tailwind CSS
<!--
This code is meant to accompany the guide originally published at https://colby.so/posts/building-a-horizontal-slider-with-stimulus-and-tailwind
It intentionally pulls in Tailwind CSS and Stimulus without a build system to simplify the guide. You shouldn't do this with a real application,
you should use a build system like webpack!
-->
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
# Additional translations at https://github.com/plataformatec/devise/wiki/I18n
zh-TW:
devise:
confirmations:
confirmed: "您的帳號已通過驗證,現在您已成功登入。"
send_instructions: "您將在幾分鐘後收到一封電子郵件,內有驗證帳號的步驟說明。"
send_paranoid_instructions: "如果我們有您的信箱,您將會收到一封驗證您的帳號的電子郵件。"
failure:
already_authenticated: "您已經登入。"
@leo424y
leo424y / gist:f5b66544561548a257755b63ac1d523c
Created June 2, 2021 09:27 — forked from rxaviers/gist:7360908
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
@leo424y
leo424y / README-rails.md
Created October 26, 2020 09:41 — forked from juliendargelos/README-rails.md
README.md template for Ruby on Rails projects
@leo424y
leo424y / create-github-issue.sh
Created October 18, 2020 02:07 — forked from RickCogley/create-github-issue.sh
Curl Script to Create a Github Issue
curl -X "POST" "https://api.github.com/repos/rickcogley/REPONAME/issues?state=all" \
-H "Cookie: logged_in=no" \
-H "Authorization: token THEd13GITHUBfb87TOKENa4FROM5eSETTINGS" \
-H "Content-Type: text/plain; charset=utf-8" \
-d $'{
"title": "A workflow alerts Operator who performs a process",
"body": "TBD",
"milestone": 5,
"assignees": [
"RickCogley",
@leo424y
leo424y / Capistrano_Installation_Manual.md
Created July 7, 2020 08:53 — forked from amolkhanorkar/Capistrano_Installation_Manual.md
Deployment Of ROR application with Capistrano By Using Remote Database Server

Deployment Of ROR application with Capistrano By Using Remote Database Server**

Steps To Deploy Application:

Prerequisites : 1. Ruby Installation Firstly install rvm using following command

Install dependencies

$ sudo apt-get install curl
@leo424y
leo424y / rbenv-install-and-using.md
Created June 18, 2020 11:57 — forked from sandyxu/rbenv-install-and-using.md
使用 rbenv 安装和管理Ruby版本

常用的几个 Ruby 版本管理工具有:rvmrbenv,ry,rbfu。rvm 应该是最早出现、使用最多的,因为过于强大以至于违背了某个 Linux 软件开发原则,所以出现了很多轻便的替代者,其中来自 37signals 的 rbenv 就很受欢迎。ry 和 rbfu 看上去更轻便,不过使用不广泛。之前使用过rvm, 这次尝试下rbenv。

我的环境是 Ubuntu14.04

1. 安装 rbenv

rbenv的源代码托管在github,在终端中,从 github 上将 rbenv 源码 clone 到本地,然后设置 $PATH。

git clone git://github.com/sstephenson/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' &gt;&gt; ~/.bashrc
@leo424y
leo424y / DockerFile_app
Created May 2, 2018 12:34 — forked from satendra02/app.DockerFile
docker+rails+puma+nginx+postgres (Production ready)
FROM ruby:2.3.1
RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs
# Configuring main directory
RUN mkdir -p /app_name
WORKDIR /app_name
# Setting env up
ENV RAILS_ENV='production'
ENV RAKE_ENV='production'
@leo424y
leo424y / nginx-and-certbot-config.md
Created April 28, 2018 01:22 — forked from rkaramandi/nginx-and-certbot-config.md
Running NGINX and CertBot Containers on the Same Host

Running NGINX and CertBot Containers on the Same Host

The Problem

A lot of people run into the problem of running Let's Encrypt's CertBot Tool and an NGINX on the same container host. A big part of this has to do with CertBot needing either port 80 or 443 open for the tool to work as intended. This tends to conflict with NGINX as most people usually use port 80 (HTTP) or 443 (HTTPS) for their reverse proxy. Section 1 outlines how to configure NGINX to get this to work, and Section 2 is the Docker command to run CertBot.

1. NGINX Configuration

I use Docker Compose (docker-compose) for my NGINX server. My docker-compose.yml file looks something like this:

@leo424y
leo424y / .typo.zshrc
Created April 10, 2018 07:40 — forked from mugijiru/.typo.zshrc
typo対策alias
# みんな大好きls周り
alias l='ls'
alias s='ls'
alias ks='ls'
# 高度に発展した、キータイプ矯正を目的とするアニメーションプログラムを入れているため使わない
# alias sl='ls'
# cdもよくミスる
alias c='cd'
alias cd..='cd ..'