Skip to content

Instantly share code, notes, and snippets.

View oguzhaneren's full-sized avatar
🐍
it depends

Oğuzhan Eren oguzhaneren

🐍
it depends
View GitHub Profile
@maeneak
maeneak / docker-compose.yaml
Last active November 8, 2024 11:33
HASSIO (Home Assistant Supervised) for Synology DSM 7 (Unsupported Installation but allows updates and fully functional)
version: '3'
services:
hassio:
image: homeassistant/amd64-hassio-supervisor
container_name: hassio_supervisor
privileged: true
security_opt:
- seccomp:unconfined
- apparmor:unconfined
@sindresorhus
sindresorhus / esm-package.md
Last active November 17, 2024 22:07
Pure ESM package

Pure ESM package

The package that linked you here is now pure ESM. It cannot be require()'d from CommonJS.

This means you have the following choices:

  1. Use ESM yourself. (preferred)
    Use import foo from 'foo' instead of const foo = require('foo') to import the package. You also need to put "type": "module" in your package.json and more. Follow the below guide.
  2. If the package is used in an async context, you could use await import(…) from CommonJS instead of require(…).
  3. Stay on the existing version of the package until you can move to ESM.
@aamnah
aamnah / quick-actions-finder-macos-big-sur.md
Last active October 23, 2023 17:39 — forked from tonysneed/Mac OS X: Open in Visual Studio Code
Add Quick Actions to Finde in macOS Big Sur to open a folder in VS Code
  • Open Automator
  • Choose Quick Action as the document type
  • Change Workflow receives current to files or folders in Finder.app
  • For Action, choose Open Finder items from the left hand sidebar
  • Change Open with to Visual Studio Code.app (find it in Other... )
  • For the Icon, change Image to "Choose..." and select the Visual Stuido Code app. It'll automatically pick the icon
  • Save it (Cmd+S) as something like "Open in VS Code"
pragma solidity ^0.4.21;
contract Ownable {
address public owner;
event OwnerChanged(address oldOwner, address newOwner);
function Ownable() {
owner = msg.sender;
}
@abdullin
abdullin / LICENSE
Last active July 10, 2020 21:31
Naive ring benchmark in .NET Core using simulated actors
MIT License 2018 Rinat Abdullin
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Http;
using Microsoft.Extensions.Logging;
namespace WebApplication1
{
public class Program
{
public static void Main(string[] args)
@thefringeninja
thefringeninja / RavenDatabaseManager.cs
Created December 8, 2017 13:00
Run Raven Tests in Ur Docker Container
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Threading.Tasks;
using Docker.DotNet;
using Docker.DotNet.Models;
using Raven.Client.Documents;
using Raven.Client.Documents.Session;
using Raven.Client.Exceptions;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.DependencyModel;
using WebApplication40;
@ruanbekker
ruanbekker / cheatsheet-elasticsearch.md
Last active October 26, 2024 17:40
Elasticsearch Cheatsheet : Example API usage of using Elasticsearch with curl
@jcalz
jcalz / builderPattern.ts
Created July 25, 2017 14:44
Builder Pattern example code
type IBuilder<T> = {
[k in keyof T]: (arg: T[k]) => IBuilder<T>
} & { build(): T }
function proxyBuilder<T>(): IBuilder<T> {
var built: any = {};
var builder = new Proxy({}, {
get: function(target, prop, receiver) {
if (prop === 'build') return () => built;
return (x: any): any => {