Skip to content

Instantly share code, notes, and snippets.

@eleven26
eleven26 / pre-commit
Created December 27, 2020 02:07 — forked from mariovalney/pre-commit
Pre-commit hook to check code with PHPCS, fix with PHPCBF and check mess with PHPMD
#!/bin/sh
#########################
# #
# Initializing #
# #
#########################
##
# You should add all tools as composer dependencies or change this path
@eleven26
eleven26 / sqlalchemy-user.py
Created March 23, 2020 09:47
py-sqlalchemy
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy import Column, Integer, String
from sqlalchemy import create_engine
from sqlalchemy.orm import sessionmaker
"""
pip install SQLAlchemy
pip install mysqlclient
"""
@eleven26
eleven26 / swoole_multi_process_test.php
Last active May 29, 2019 10:00
php multi process use swoole
<?php
echo <<<EOS
用法:
1. php swoole_multi_process_test.php 启动
2. php swoole_multi_process_test.php stop 停止
EOS;
class ProcessManager