Skip to content

Instantly share code, notes, and snippets.

@ericlagergren
ericlagergren / gist:2ce4e0ef82871d513aa2
Created May 12, 2015 04:15
Simple fgetc implementation in Go
package main
import (
"fmt"
"os"
"syscall"
)
type File struct {
file *os.File
@ayebrian
ayebrian / vmware.md
Last active January 15, 2025 08:11
VMware ESXi 8 / vCenter 8 / Workstation 17 license key 2024
@ivanscdo
ivanscdo / change_datetime.md
Last active January 15, 2025 08:10
Change Git Log Datetime Format

Change Git Log Datetime Format

Change the default format to something more human readable.


Run the following command:

git config --global log.date format:"%a %b %d %Y %I:%M:%S %p"
@Swader
Swader / build.dart
Created March 14, 2013 18:25
Recursive folder copy in Dart: An updated Dart web_ui build script which recursively copies a folder and its contents to another location. Useful when building for a defined vhost (e.g. Apache with PHP back end for your Dart app) and don't want the build script to relativize your paths to go "one folder up" back from /out into /web to get CSS an…
import 'dart:io';
import 'package:web_ui/component_build.dart';
// Ref: http://www.dartlang.org/articles/dart-web-components/tools.html
main() {
build(new Options().arguments, ['web/index.html']);
//recursiveFolderCopySync('web/assets', 'web/out/assets');
}
bool isSymlink(String pathString) {
@npwolf
npwolf / copy_github_autolinks.py
Created January 15, 2025 00:08
Copy github autolinks from one repo to all repos in an organization
@mikepianka
mikepianka / README.txt
Last active January 15, 2025 08:04
Python http.server exe
This is Python's http.server that has been bundled to an .exe using PyInstaller. You can use it as a local web server for testing.
Run the local server
1. Copy the server.exe into the folder you want to serve and then double click it to start the local server.
2. A window will pop up letting you know the server is running on port 8000.
3. Open http://localhost:8000/ in your web browser.
4. When you are done, simply close the server.exe window to stop the local server.
If you have another service running on port 8000, you can run on a different port like so:
1. Open Command Prompt
@yidas
yidas / codeiginter-server-config.md
Last active January 15, 2025 08:04
Codeigniter 3 server configuration for Nginx & Apache

Codeigniter 3 server configuration for Nginx & Apache

Web Server Site Configuration

Recommended Apache Configuration

Use the following configuration in Apache's httpd.conf file or within a virtual host configuration. Note that you should set DocumentRoot and ServerName fit to your environment:

@benigumocom
benigumocom / SpeechBubble.swift
Last active January 15, 2025 08:01
【SwiftUI】Create Animated Speech Bubble 👉 https://android.benigumo.com/20240827/speech-bubble/
import SwiftUI
struct SpeechBubble: View {
var count: Int
var body: some View {
HStack(spacing: 0) {
Rectangle()
.fill(.red)
.rotationEffect(.degrees(45))
@wtw24
wtw24 / docker_rus.md
Last active January 15, 2025 08:01
Шпаргалка с командами Docker

Шпаргалка с командами Docker

1552317264965 1552317537397 1552317711879

1552318467562 1552318531067 1552318577900 1552318614839

@grimmdev
grimmdev / Curved.shader
Created July 17, 2015 05:32
Subway Surfer like Curved World Shader for Unity
Shader "Custom/Curved" {
Properties {
_MainTex ("Base (RGB)", 2D) = "white" {}
_QOffset ("Offset", Vector) = (0,0,0,0)
_Dist ("Distance", Float) = 100.0
}
SubShader {
Tags { "RenderType"="Opaque" }
Pass
{