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
@echo off | |
:: see https://www.makeuseof.com/tag/3-quickest-ways-turn-computer-screen-windows/ | |
:: see https://gist.github.com/EugeneLoy/150044d04b08e35d09e164c864e78da7 | |
powershell (Add-Type '[DllImport(\"user32.dll\")]^public static extern int PostMessage(int hWnd, int hMsg, int wParam, int lParam);' -Name a -Pas)::PostMessage(-1,0x0112,0xF170,2) | |
:: see https://www.pcreview.co.uk/threads/create-a-batch-file-to-lock-computer.3747748/post-12994020 | |
Rundll32.exe User32.dll,LockWorkStation |
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
using System; | |
using System.Collections.Generic; | |
using System.Diagnostics; | |
using System.IO; | |
using System.Linq; | |
struct Program | |
{ | |
static void 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
// http://zyan.com.de | |
// | |
// Compile using: csc test.cs /r:Zyan.Communication.dll | |
// | |
// Start up test.exe several times. | |
// The first process is the server, the rest are clients. | |
// | |
using System; | |
using System.Collections.Concurrent; |
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
// http://zyan.com.de | |
// | |
// Compile using: csc test.cs /r:Zyan.Communication.dll | |
// | |
// Start up test.exe several times. | |
// The first process is the server, the rest are clients. | |
// | |
using System; | |
using System.Collections.Concurrent; |
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
using System; | |
using System.Linq; | |
using System.Linq.Expressions; | |
using Mono.Linq.Expressions; | |
using Sprache; | |
using Sprache.Calc; | |
namespace Pascal | |
{ | |
class Program |
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
// Compile the code using: | |
// csc.exe test.cs | |
// /r:OpenTelemetry.Exporter.Jaeger.dll | |
// /r:OpenTelemetry.Api.dll | |
// /r:OpenTelemetry.dll | |
// /r:System.Diagnostics.DiagnosticSource.dll | |
using System; | |
using System.Collections.Generic; | |
using System.Diagnostics; |
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
#1) Create a new repo named "my-npm" and let github initialize it with a README (screenshot below) | |
#2) Clone it to your computer | |
git clone git@github.com:SmallRoomLabs/my-npm.git | |
#3) Go to the clone and create a new empty branch for the first package | |
cd my-npm | |
git checkout --orphan logger | |
#4) Delete all files in the folder |
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
// http://zyan.com.de | |
// | |
// Compile using: csc test.cs /r:Zyan.Communication.dll | |
// | |
// Start up test.exe several times. | |
// The first process is the server, the rest are clients. | |
// | |
using System; | |
using System.Collections.Concurrent; |
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
// Compile this code using: csc ipctest.cs /r:Zyan.Communication.dll | |
// First run — starts server. | |
// Second run — starts client. | |
using System; | |
using System.Linq; | |
using System.Text; | |
using Zyan.Communication; | |
using Zyan.Communication.Protocols.Ipc; |
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
// csc test.cs /r:Zyan.Communication.dll /debug | |
using System; | |
using System.Runtime.Serialization; | |
using System.Security; | |
using System.Text; | |
using System.Threading; | |
using Zyan.Communication; | |
using Zyan.Communication.Protocols.Tcp; | |
using Zyan.Communication.Security; |
NewerOlder