当你要把自己用过的电脑在咸鱼上卖掉或送给他人时,为防止个人敏感信息泄露,最好先把磁盘被删除的文件彻底清除,使其永远无法恢复。 以下命令将使D盘上所有已被删除的文件无法恢复。 cipher /w:D 其中 D 就是要操作的盘符。执行此操作时间较长,他的原理就是在磁盘上反复写一个特别大的文件,覆盖空闲磁盘空间。 Ctrl+C可以中断该命令,中断该命令时需手动删除 cipher创建的文件,否则它会占用磁盘的较大磁盘空间。
Category: Web
free logo maker
https://www.designfreelogoonline.com/logoshop/design-free-logo-3d-abstract-logo-template/ 可以导出svg, 用文本编辑器打开文件,把里面相关的版权图片删除, 即可得到一个无码的 SVG LOGO https://logotypemaker.com/home/brands
宝塔Linux Nginx WordPress配置伪静态配置
进入宝塔的主机管理面板-> 设置-> 伪静态写入如下配置即可 # wordpress location / { try_files $uri $uri/ /index.php?$args; } 以下配置不写也可 # wordpress location = /wp-admin { rewrite ^ /wp-admin/ permanent; } 参考: http://www.nginx.cn/300.html
Google Clould Storage
前置: 存在Google Clould 账号和 Google Clould项目 1. 创建应用程序 2. 配置IAM权限 3. 创建bucket 4. 上传文件测试 5. 公开文件 添加 allUsers权限 创建项目 其他 Bucket is requester pays bucket but no user project provided 把Bucket 的 Requester Pays 改为false即可 Insufficient Permission
CURL 用法
curl http://www.geeksforgeeks.org Post Json数据 curl -H “Content-Type:application/json” -H “Data_Type:msg” -X POST –data ‘{“text”: “Hello world”}’ http://127.0.0.1:8000/tts 下载,显示进度 curl -o hello.zip ftp://speedtest.tele2.net/1MB.zip 参考: https://www.geeksforgeeks.org/curl-command-in-linux-with-examples/ https://www.cnblogs.com/hujiapeng/p/8470099.html
Git项目初始化
Command line instructions Git global setup git config –global user.name “HeHe” git config –global user.email “hehe@qq.com” Create a new repository git clone git@gitlab.xxx.com:aaa/bbb.git cd graylog touch README.md git add README.md git commit -m “add README” git push -u origin master Existing folder cd existing_folder git init git remote add origin git@gitlab.xxx.com:aaa/bbb.git git add . git…
Angular 2.0
Angular2.0 http://angular.io https://angular.cn Installation npm install -g @angular/cli Create Project ng new my-app Start project cd my-app ng serve –open Open in browser open http://localhost:4200 Angular Cli WIKI https://github.com/angular/angular-cli/wiki Angular Cli ng new ng serve ng generate ng lint ng test ng e2e ng build ng get/ng set ng doc ng eject ng xi18n Angular…
phpstorm setup
Download https://www.jetbrains.com/phpstorm/ PhpStorm 2017.3.4 License Server http://license.topnguyen.net Install Symfony Plugin in PhpStorm Open PhpStorm Menu Perferences -> Plugins -> Browser Repositories Search “Symfony Plugin” Install -> OK Install phpunit6 & Setup wget -O phpunit https://phar.phpunit.de/phpunit-6.phar chmod +x phpunit ./phpunit –version Perferences -> Languages & Framworks -> PHP -> Test Frameworks Click “+” -> “PHPUnit Local”…
Homebrew install web development envirment
Nginx brew install nginx PHP brew install php71 brew install homebrew/php/php71-pcntl brew install homebrew/php/php71-xdebug MySQL brew install mysql
doctrine createQueryBuilder count and not exists
$qb = $this->o->createQueryBuilder(‘o’); $sub = $this->em->createQueryBuilder(); $sub->select(“o.id”); //notice this : cause e.offer is foreign key of o.id $sub->from(ExcludedByOffer::class, “e”); $sub->andWhere(‘e.offer = o.id’) ->andWhere(‘e.aff = :aff’); $qb->select(‘count(o.id)’) ->where(‘o.adv=:adv’) ->andWhere($qb->expr()->not($qb->expr()->exists($sub->getDQL()))) ->setParameters([‘adv’ => $adv, ‘aff’ => $aff ]); return $qb->getQuery()->getSingleScalarResult(); 参考 https://stackoverflow.com/questions/31536137/doctrine-not-exists-subquery/31536545 https://stackoverflow.com/questions/9214471/count-rows-in-doctrine-querybuilder