start new:
tmux
start new with session name:
tmux new -s myname
| struct __declspec(uuid("905a0fef-bc53-11df-8c49-001e4fc686da")) IBufferByteAccess : ::IUnknown | |
| { | |
| virtual HRESULT __stdcall Buffer(uint8_t** value) = 0; | |
| }; | |
| struct CustomBuffer : implements<CustomBuffer, IBuffer, IBufferByteAccess> | |
| { | |
| std::vector<uint8_t> m_buffer; | |
| uint32_t m_length{}; |
| #include "winrt/Windows.Foundation.h" | |
| struct __declspec(uuid("5b0d3235-4dba-4d44-865e-8f1d0e4fd04d")) __declspec(novtable) IMemoryBufferByteAccess : ::IUnknown | |
| { | |
| virtual HRESULT __stdcall GetBuffer(uint8_t** value, uint32_t* capacity) = 0; | |
| }; | |
| using namespace winrt; | |
| using namespace Windows::Foundation; |
| - Open Automator | |
| - File -> New -> Service | |
| - Change "Service Receives" to "files or folders" in "Finder" | |
| - Add a "Run Shell Script" action | |
| - Change "Pass input" to "as arguments" | |
| - Paste the following in the shell script box: open -n -b "com.microsoft.VSCode" --args "$*" | |
| - Save it as something like "Open in Visual Studio Code" |
| private static OkHttpClient getUnsafeOkHttpClient() { | |
| try { | |
| // Create a trust manager that does not validate certificate chains | |
| final TrustManager[] trustAllCerts = new TrustManager[] { | |
| new X509TrustManager() { | |
| @Override | |
| public void checkClientTrusted(java.security.cert.X509Certificate[] chain, String authType) throws CertificateException { | |
| } | |
| @Override |