Skip to content

Instantly share code, notes, and snippets.

View rohitpaulk's full-sized avatar

Paul Kuruvilla rohitpaulk

View GitHub Profile
@rohitpaulk
rohitpaulk / swift_build_madness.Dockerfile
Created February 4, 2020 06:51
Swift build madness
RUN mkdir /root/Scribble-Server
ADD Tests /root/Scribble-Server/Tests
ADD Package.swift /root/Scribble-Server
ADD Package.resolved /root/Scribble-Server
# Add a dummy file for resolving dependencies and pre-building first
ADD Sources/DummyForDependencies/main.swift /root/Scribble-Server/Sources/ScribbleServer/main.swift
ADD Sources/DummyForDependencies/DummyModel.swift /root/Scribble-Server/Sources/CanvasModel/DummyModel.swift
@rohitpaulk
rohitpaulk / huge_file.go
Last active March 17, 2020 10:16
Write a huge file in Go
package main
import (
"fmt"
"os"
"strings"
)
func main() {
f, err := os.Create("/tmp/dat2")
@rohitpaulk
rohitpaulk / server.c
Created March 24, 2020 12:22
Redis Starter C
#include <stdio.h>
#include <stdlib.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netinet/ip.h>
#include <string.h>
#include <errno.h>
#include <unistd.h>
int main() {
@rohitpaulk
rohitpaulk / definitions.yml
Created June 8, 2022 22:37
Course definitions
- language: clojure
file_mappings:
- source: starter_templates/README.md
target: README.md
- source: starter_templates/codecrafters.yml
target: codecrafters.yml
- source: starter_templates/clojure/.gitignore
target: .gitignore
- source: starter_templates/clojure/project.clj
target: project.clj