Skip to content

Instantly share code, notes, and snippets.

View geocine's full-sized avatar
🤖
지식은 행동으로 번성하고, 게으르면 시들어간다.

Aivan Monceller geocine

🤖
지식은 행동으로 번성하고, 게으르면 시들어간다.
View GitHub Profile
@enepomnyaschih
enepomnyaschih / base64.js
Last active March 17, 2025 03:14
https://www.npmjs.com/package/byte-base64 - Encode JS Uint8Array, simple array of bytes or native JS string to base64 and back
/*
MIT License
Copyright (c) 2020 Egor Nepomnyaschih
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is

Getting Started

  • Install Dependencies
    npm init -y
    npm install --save-dev vue @vue/cli http-server
    

Create Web Component

  • Create vue component src/my-component.vue.
    <template>
    
@aelbore
aelbore / vue-to-js.md
Last active February 1, 2019 03:40
vue file to js file
const ts = require('typescript');
const fs = require('fs');
const path =  require('path');
const prettier = require('prettier');

const { promisify } = require('util');
const { globFiles, clean, mkdirp } = require('aria-fs');

const writeFileAsync = promisify(fs.writeFile);
@richlander
richlander / instructions.md
Last active March 24, 2024 14:54
Installing .NET Core 3.0 on Linux ARM64

Installing .NET Core on Linux ARM64

The following intructions can be used to install .NET Core on Linux ARM64.

Pro tip: Check out .NET Core Docker files to determine the exact instructions for installing .NET Core builds, for example .NET Core 3.1 ARM32 SDK Dockerfile.

Installing .NET Core Globally

The following instructions install the latest .NET Core globally. It isn't required to do that, but it provides the best experience.

@robbi5
robbi5 / readme.md
Last active July 13, 2018 09:39
chrome headless on uberspace7

chrome headless on uberspace7

cd ~/tmp

download and extract chrome

wget -O chrome-linux.zip https://download-chromium.appspot.com/dl/Linux_x64?type=snapshots
unzip chrome-linux.zip
@subfuzion
subfuzion / dep.md
Last active July 25, 2024 03:38
Concise guide to golang/dep

Overview

This gist is based on the information available at golang/dep, only slightly more terse and annotated with a few notes and links primarily for my own personal benefit. It's public in case this information is helpful to anyone else as well.

I initially advocated Glide for my team and then, more recently, vndr. I've also taken the approach of exerting direct control over what goes into vendor/ in my Dockerfiles, and also work from isolated GOPATH environments on my system per project to ensure that dependencies are explicitly found under vendor/.

At the end of the day, vendoring (and committing vendor/) is about being in control of your dependencies and being able to achieve reproducible builds. While you can achieve this manually, things that are nice to have in a vendoring tool include:

@ceduliocezar
ceduliocezar / sonarqube-postgres-docker.md
Created August 1, 2017 18:58
How easily run Sonar Qube and PostgresSQL with Docker Containers

TL;DR

After installing Docker, follow three steps:
Step 1:
Run: docker network create mynet

Step 2:
Run: docker run --name sonar-postgres -e POSTGRES_USER=sonar -e POSTGRES_PASSWORD=sonar -d -p 5432:5432 --net mynet postgres

Step 3:
Run: docker run --name sonarqube -p 9000:9000 -e SONARQUBE_JDBC_USERNAME=sonar -e SONARQUBE_JDBC_PASSWORD=sonar -e SONARQUBE_JDBC_URL=jdbc:postgresql://sonar-postgres:5432/sonar -d --net mynet sonarqube:5.6

@ReedD
ReedD / dragScrollEnd.ts
Created May 26, 2017 04:23
Observable for drag-scroll-end.
import * as Rx from 'rxjs'
const pointerDown$ = Rx.Observable.race(
Rx.Observable.fromEvent(window, 'mousedown'),
Rx.Observable.fromEvent(window, 'touchstart'),
)
const drag$ = pointerDown$.flatMap(() => {
const pointerUp$ = Rx.Observable.race(
Rx.Observable.fromEvent(window, 'mouseup'),
@shashankmehta
shashankmehta / setup.md
Last active November 18, 2024 18:33
Setup PHP and Composer on OSX via Brew

First install Brew on your MAC

  • Setup Brew: ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  • brew update
  • brew tap homebrew/dupes
  • brew tap homebrew/php
  • Install PHP 7.0.+ brew install php70
  • Install mcrypt: brew install mcrypt php70-mcrypt
  • Finally, install composer: brew install composer
@DanielRobinsonSoftware
DanielRobinsonSoftware / MutationCollectionTests.cs
Created December 12, 2016 01:01
Mutate a list of custom objects in GraphQL for .NET
using System.Collections.Generic;
using GraphQL.Types;
using Xunit;
namespace GraphQL.Tests.Execution.Collections
{
public class Foo
{
public Foo()
{