Skip to content

Instantly share code, notes, and snippets.

@lazabogdan
lazabogdan / boot2docker-nfs.rb
Last active August 29, 2015 14:19 — forked from mattes/boot2docker-nfs.rb
docker-machine / boot2docker with NFS instead of vboxsf; it shares /Users and the current directory to /apps/$current_directory_basename
#!/usr/bin/env ruby
# Usage
# $ docker-machine create my-machine123 -d virtualbox
# $ ruby <(curl -L http://git.io/vvFRw) my-machine123
# https://gist.github.com/lazabogdan/fa769cb5f80085a2b78f
require 'erb'
app_path = Dir.getwd
#!/bin/sh
remove_dangling_images() {
echo "Removing dangling images ..."
docker rmi $(docker images -f dangling=true -q)
}
remove_unused_images() {
echo "Removing unused images ..."
docker images -aq | xargs -l10 docker rmi
@lazabogdan
lazabogdan / Utilities.swift
Created September 24, 2015 13:31
CouchbaseLite Swift
//
// Utilities.swift
// swift-couchbaselite
//
// Created by Jens Alfke on 9/17/14.
// Copyright (c) 2014 Couchbase, Inc. All rights reserved.
//
import Foundation
@lazabogdan
lazabogdan / SassMeister-input.scss
Last active August 14, 2020 18:10
Sass spacing utility
// ----
// libsass (v3.3.2)
// ----
$spacer: 1rem;
$spacer-x: $spacer;
$spacer-y: $spacer;
$spacers: ();
@lazabogdan
lazabogdan / SassMeister-input.scss
Last active August 30, 2024 00:40
Sass sizing utility
// ----
// libsass (v3.3.2)
// ----
$sizer: 1rem;
$sizer-increment: 5;
$sizers: ();
@for $i from 1 through 20 {
@lazabogdan
lazabogdan / .babelrc
Created August 18, 2018 11:26
.babelrc ie11
{
"plugins": ["transform-runtime"],
"presets": [
["env", {
"targets": {
"ie": "11",
"browsers": ["last 2 versions"]
}
}]
]
@lazabogdan
lazabogdan / rails_deployment.md
Created September 6, 2023 05:30 — forked from jamessom/rails_deployment.md
Rails deployment to AWS EC2

Rails Deployment to AWS EC2

Stack : (Nginx + Phusion Passenger + Postgresql)

  • Step -1

    To Launch an EC2 instance from aws console with all the credentials and configurations hooked.

  • Step-2

@lazabogdan
lazabogdan / private_fork.md
Created December 4, 2023 07:06 — forked from 0xjac/private_fork.md
Create a private fork of a public repository

The repository for the assignment is public and Github does not allow the creation of private forks for public repositories.

The correct way of creating a private frok by duplicating the repo is documented here.

For this assignment the commands are:

  1. Create a bare clone of the repository. (This is temporary and will be removed so just do it wherever.)

git clone --bare [email protected]:usi-systems/easytrace.git

@lazabogdan
lazabogdan / test.txt
Created August 21, 2024 18:42
Test Gist created by LangChain tool
This is updated content by LangChain tool
@lazabogdan
lazabogdan / github_gist_tools.py
Created August 21, 2024 18:50
GitHub Gist Tools for LangChain
import os
from typing import Dict
from langchain.tools import tool
import requests
# Replace with your GitHub token or use environment variables
GITHUB_TOKEN = "your_github_token_here"
@tool