Skip to content

Instantly share code, notes, and snippets.

@bazzel
bazzel / README.md
Last active May 26, 2021 04:20
Rails 6 and Bootstrap 4

This blogpost shows how to setup Rails 6 with Bootstrap 4.

This snippet shows a somehow different and less customized approach.

$ rails new rails6-bootstrap4
$ bundle --binstubs
$ yarn add bootstrap jquery popper.js expose-loader
@iamdbc
iamdbc / logrotate-puma-rails
Last active September 20, 2023 14:57
logrotate for puma on rails
# file location: /etc/logrotate.d
/home/deploy/app/your-app/shared/log/*.log {
daily
missingok
rotate 14
compress
delaycompress
dateext
notifempty
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'
" common
Plugin 'scrooloose/nerdtree'
Plugin 'valloric/youcompleteme'
@sheharyarn
sheharyarn / RVFragment.java
Last active December 18, 2019 06:39
A simple Fragment with RecyclerView
/**
* RVFragment - Fragment with a simple RecyclerView that
* only takes Strings
*
* Usage:
* RVFragment rvf = new RVFragment();
*
* @author Sheharyar Naseer
*/
@aryklein
aryklein / linux-mailserver.md
Last active March 11, 2020 09:53
Another linux mail server guide

Setting up a Linux system as a mail server with virtual users

Introduction

Setting up an email server is a difficult process involving a number of different programs, each of which needs to be properly configured. The best approach is to install and configure each individual component one by one, ensuring that each one works, and gradually build your mail server.

This guide covers how to set up a mail server on Debian 8. Most of the steps also should work on Ubuntu 14.04 LTS, considering that Ubuntu 14.04 LTS does not use systemd.

@ciastek
ciastek / README
Created February 23, 2016 10:51 — forked from anonymous/README
Use bootstrap-sass npm package with Phoenix's brunch
1) install npm packages
2) update brunch-config.js
3) remove Bootstrap from web/static/css/app.css
4) rename web/static/css/app.css to web/static/css/app.scss
5) update web/static/css/app.scss
@neil-h
neil-h / _bootstrap-em.scss
Last active November 17, 2017 16:12 — forked from jasny/bootstrap-em.less
A Sass port of jasny/bootstrap-em.less
@function strip-units($number) {// From : http://stackoverflow.com/a/12335841/1339426
@return $number / ($number * 0 + 1);
}
/**
* Use em or rem font-size in Bootstrap 3
* Ported from Less version here: https://gist.github.com/jasny/9731895
*/
$font-size-root: 18px;
$font-unit: 1rem; // Pick em or rem here
@MeanEYE
MeanEYE / config
Created July 8, 2014 07:54
i3 config
# set modifier to Super key
set $mod Mod4
# workspaces
set $ws_chat 1: Chat
set $ws_web 2: Web
set $ws_code 3: Code
set $ws_misc 4: Misc
set $ws_fm 5: FM
@plepe
plepe / gist:52ecc9f18efb32c68d18
Last active June 6, 2024 22:23
MDADM and LVM cheat sheet

mdadm

Glossary:

  • md: multiple devices
command description
cat /proc/mdstat show status of all raids
mdadm --detail /dev/md0 detailed status of raid md0
@mariussturm
mariussturm / gist:061b9f4861ef1292aa60
Last active February 1, 2017 13:16
How to pair Firefox 29 with Owncloud's mozilla_sync / Weave
_Go to your Owncloud installation <https://myowncloud/remote.php/mozilla_sync> and accept the SSL Certificate
_Open about:config
_Create: services.sync.username <string> the value should be a hash not the username itself. (You only need the hash if the
sync was setup with a pre FF29, if you start from scratch the string doesn't matter)
You can look this up in an older browser or in the logs of your Owncloud server!!
_Go to: Preferences -> Sync -> Setup Firefox sync (you should see the old UI now)
'I Have an Account'
'I don't have the device with me'
'Account' - again use the hash NOT the actual username!