This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
GITLAB_URL="https://example.gitlab.com/" | |
PROJECT_ID="2" # get this id via the repo/project's overview page | |
ACCESS_TOKEN="glpat-abc" | |
# Create a new merge request | |
curl --header "Private-Token: $ACCESS_TOKEN" \ | |
"$GITLAB_URL/api/v4/projects/$PROJECT_ID/merge_requests" \ | |
--data "source_branch=my-branch" \ | |
--data "target_branch=main" \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define WIN32_LEAN_AND_MEAN // just say no to MFC | |
#define INIT_GUID | |
#include "hge.h" | |
#include <hgesprite.h> | |
#include <hgefont.h> | |
#include <hgecolor.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <atomic> | |
#include <cassert> | |
#include <iostream> | |
#include <list> | |
#include <memory> | |
#include <mutex> | |
#include <optional> | |
#include <thread> | |
#include <vector> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CLIENT SIDE: | |
#include <iostream> | |
#include <winsock2.h> | |
using namespace std; | |
#pragma comment(lib,"ws2_32.lib") | |
#pragma warning(disable:4996) | |
#define SERVER "127.0.0.1" // or "localhost" - ip address of UDP server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* fork.c | |
* Experimental fork() on Windows. Requires NT 6 subsystem or | |
* newer. | |
* | |
* Copyright (c) 2012 William Pitcock <nenolod@dereferenced.org> | |
* | |
* Permission to use, copy, modify, and/or distribute this software for any | |
* purpose with or without fee is hereby granted, provided that the above | |
* copyright notice and this permission notice appear in all copies. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Two dashes start a one-line comment. | |
--[[ | |
Adding two ['s and ]'s makes it a | |
multi-line comment. | |
--]] | |
---------------------------------------------------- | |
-- 1. Variables and flow control. | |
---------------------------------------------------- |