我好久不用Xcode,发现以前在右侧边栏的UI组件库不见了,找了半天也没找到,google一搜,还真有不少人我和一样https://stackoverflow.com/questions/51051532/xcode-10-where-are-the-ui-elements
View -> Libraries -> Show Library
或者快捷键 Command + Shift + L
1830 articles
我好久不用Xcode,发现以前在右侧边栏的UI组件库不见了,找了半天也没找到,google一搜,还真有不少人我和一样https://stackoverflow.com/questions/51051532/xcode-10-where-are-the-ui-elements
View -> Libraries -> Show Library
或者快捷键 Command + Shift + L
Use find to list the current folder:
find . -print | sed -e 's;[^/]*/;|____;g;s;____|; |;g'
Add to ~/.bash_profile or ~/.zshrc
alias tree="find . -print | sed -e 's;[^/]*/;|____;g;s;____|; |;g'"
Or install the tree with brew
brew install tree
I installed the ansible via pip install
, and there are several issues here:
Here you should create a file ~/.ansible.cfg
[defaults]
inventory =~/.ansible/hosts
sudo_user=root
remote_port=22
host_key_checking=False
remote_user=root
log_path=~/.ansible/log/ansible.log
module_name=command
private_key_file=~/.ssh/id_rsa
To reverse all migrations for an app, you can run:
python manage.py migrate my_app zero
To remove directories, run
git clean -f -d
or git clean -fd
To remove ignored files, run
git clean -f -X
or git clean -fX
To remove ignored and non-ignored files, run
git clean -f -x
or git clean -fx
pip install -e /path/to/package
ysql> SET foreign_key_checks = 0;
mysql> drop table photologue_gallery;
mysql> drop table photologue_photo;
mysql> SET foreign_key_checks = 1;
Check what's the CONSTRAINT name and the FOREIGN KEY name:
SHOW CREATE TABLE table_name;
Remove both the CONSTRAINT name and the FOREIGN KEY name:
ALTER TABLE table_name
DROP FOREIGN KEY the_name_after_CONSTRAINT,
DROP KEY the_name_after_FOREIGN_KEY;
Or simply run this if you know the foreign key name:
alter table footable drop foreign key fooconstraint
原文:https://stackoverflow.com/questions/838354/mysql-removing-some-foreign-keys
I want to recreate the migrations, so I deleted files under migrations folder, and drop the database. And try this python manage.py makemigrations
, it reponse No changes detected
.
Create the database again, and clear files and folders under migrations, then try the following:
python manage.py makemigrations --empty appname
python manage.py makemigrations
python manage.py migrate
It works!
mysql server was installed by brew install mysql
ERROR: Failed building wheel for mysqlclient
ld: library not found for -lssl
clang: error: linker command failed with exit code 1 (use -v to see invocation)
error: command 'clang' failed with exit status 1
Exception: Wrong MySQL configuration: maybe https://bugs.mysql.com/bug.php?id=86971 ?