The file sync is based on unison.
- Download current release of unison
import argparse | |
import os | |
from pathlib import Path | |
import shutil | |
import subprocess | |
import tempfile | |
from typing import List | |
parser = argparse.ArgumentParser( | |
prog='GoCrossCompile', |
import functools | |
from asgiref.sync import async_to_sync | |
from django.contrib.auth.signals import user_logged_out | |
from channels.layers import get_channel_layer | |
def __ws_login_required_signal_handler(sender, request, user, **kwargs): | |
print(request.session.session_key) | |
channel_layer = get_channel_layer() | |
async_to_sync(channel_layer.group_send)(f"SESSION-{request.session.session_key}", {"type": "close", "code": None}) | |
user_logged_out.connect(__ws_login_required_signal_handler, dispatch_uid="__ws_login_required_signal_handler") |
;MIT License | |
; | |
;Copyright (c) 2020 Rubin Romeo Raithel | |
; | |
;Permission is hereby granted, free of charge, to any person obtaining a copy | |
;of this software and associated documentation files (the "Software"), to deal | |
;in the Software without restriction, including without limitation the rights | |
;to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
;copies of the Software, and to permit persons to whom the Software is | |
;furnished to do so, subject to the following conditions: |
{"lastUpload":"2021-09-21T21:36:36.851Z","extensionVersion":"v3.4.3"} |
import win32pipe, win32file | |
class PipeServer(): | |
def __init__(self, pipeName): | |
self.pipe = win32pipe.CreateNamedPipe( | |
r'\\.\pipe\\'+pipeName, | |
win32pipe.PIPE_ACCESS_OUTBOUND, | |
win32pipe.PIPE_TYPE_MESSAGE | win32pipe.PIPE_READMODE_MESSAGE | win32pipe.PIPE_WAIT, | |
1, 65536, 65536, | |
0, |
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
from Crypto.Cipher import AES | |
import base64 | |
import random | |
import hashlib | |
import os | |
class AesCrypt256: |