Python单例模式 1.装饰器实现单例:1234567891011121314def singleton(cls): instances = {} def getinstance(*args, **kwargs): if cls not in instances: instances[cls] = cls(*args, **kwargs) return instances[cls] ret 2021-09-26 Python Python
Python使用Subprocess.Popen启动进程 简介:subprocess.Popen()用于创建一个子进程,并连接到子进程的标准输入/输出/错误管道,来管理进程 Popen原型:12345678910111213141516#原型中带参数的值都是默认值class subprocess.Popen( args, bufsize=0, executable=None, stdin=None, stdout=None, stderr=None, 2021-09-13 Python Subprocess Python Subprocess
windows程序提权至system 问题:程序没有最高权限,无法进行高权限的操作 (即使管理员权限也无法满足的情况下) 解决方案:使用C++实现在win10系统上获取系统的system权限 通过system父进程创建子进程方式给程序提权 核心代码: 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950 2021-07-22 windows windows
Ubuntu下git的安装与使用 安装:sudo apt-get install git 配置:git config --global user.name "你的Git用户名" git config --global user.email "你的邮箱地址" 创建公钥:Git生成SSH公钥 使用:初始化git环境 git init 关联Git仓库 git remote add origi 2021-07-21 github github
ubuntu安装node.js 安装方式:从 NodeSource 源安装 安装:nodejs官网 https://nodejs.org 看最新的版本号 添加对应源(setup_14.x对应14.x.x版本) curl -sL https://deb.nodesource.com/setup_14.x | sudo -E bash - 安装node.js sudo apt-get install -y nodejs 查看版本 2021-07-21 node.js node.js
ubuntu安装使用openresty 安装:官网地址:http://openresty.org/cn/linux-packages.html 安装导入 GPG 公钥时所需的几个依赖包(整个安装过程完成后可以随时删除它们) sudo apt-get -y install --no-install-recommends wget gnupg ca-certificates 导入 GPG 密钥 wget -O - https://open 2021-07-15 ubuntu openresty ubuntu openresty
Ubuntu下mysql的安装使用与卸载 一、安装:先使用 wget 下载存储库软件包手动下载地址:https://dev.mysql.com/downloads/repo/apt/ wget -c https://repo.mysql.com//mysql-apt-config_0.8.17-1_all.deb 然后使用以下 dpkg 命令安装下载好的 MySQL 存储库软件包(选择mysql版本)sudo dpkg -i mysql 2021-07-14 mysql mysql
Ubuntu无法使用root用户登陆 问题:以root用户远程登陆ubuntu提示: Please login as the user "ubuntu" rather than the user "root" 解决办法一、编辑ssh登录方式:1234567891011121314#编辑SSH文件 sudo vim /etc/ssh/sshd_config#密码认证改为 yesPasswordA 2021-07-13 Ubuntu Ubuntu
github免密码push 生成 SSH Key:12#输入自己的github注册邮箱ssh-keygen -t rsa -C "[email protected]" 提示直接回车成功的话会在 ~/ 下生成 .ssh 文件夹 12#打开 id_rsa.pub复制里面的 keyvim ~/.ssh/id_rsa.pub 到 github 上,进入 Account => Settings =&g 2021-07-13 github github
CE防检测 下载lazarus下载地址:https://www.lazarus-ide.org/index.php?page=downloads CE源码下载地址:https://github.com/cheat-engine/cheat-engine 打开源码项目用lazarus打开Cheat Engine文件夹中cheatengine.lpi 修改标题在view菜单中点击MainForm:TMainFo 2021-07-09 CE CE