This file contains hidden or 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
version: '3.8' | |
services: | |
nginx: | |
image: 'nginxproxy/nginx-proxy:latest' | |
container_name: 'nginx-proxy' | |
volumes: | |
- 'html:/usr/share/nginx/html' | |
- 'dhparam:/etc/nginx/dhparam' |
This file contains hidden or 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
using System.Runtime.InteropServices; | |
//Call Win32 API for opening a Messagebox (This does not require any other libarys) | |
[DllImport("user32.dll", CharSet = CharSet.Unicode)] | |
static extern int MessageBox(IntPtr hWnd, String text, String caption, uint type); | |
MessageBox(new IntPtr(0), "Message", "Title", 0); |
This file contains hidden or 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
using System.Net.Http.Headers; | |
HttpClient client = new HttpClient(); | |
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Basic", "TOKEN"); //Add Authentication (extra) | |
var data = @"{JSON}"; //JSON String | |
var buffer = System.Text.Encoding.UTF8.GetBytes(data); | |
var byteContent = new ByteArrayContent(buffer); | |
byteContent.Headers.ContentType = new MediaTypeHeaderValue("application/json"); //Type Of Data | |
var response = await client.PostAsync("http://127.0.0.1/createSomething", byteContent); //URL | |
var responseString = await response.Content.ReadAsStringAsync(); | |
Console.WriteLine(responseString); //out to terminal (extra) |
This file contains hidden or 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
Hell | |
├── main.go | |
└── world | |
└── test.go | |
------------------------------------------|------------------------------------------ | |
main.go: |test.go: | |
package main | package world | |
import "example.com/modulename/world" | import "fmt" | |
func main(){world.Quest()} | func Quest(){fmt.Println("test done!")} | |
------------------------------------------|------------------------------------------ |