Basic use of SVN (1.3.9)

About TortoiseSVN (svn)

Online documentation(Chinese, simplified)

The command for Mac OS:

  • svn help (?, h)         // you can enter “svn help” or “svn ?” or “svn h” in terminal to get some help
  • svn add path
  • svn add *.suffix       //Add a file with the specified suffix       like:svn add * .py
  • svn add . –no-ignore –force     // Add all the files in the current directory
  • svn update(up)
  • svn checkout(co) path
  • svn commit -m “message note” ./         //commit files in the current directory
  • svn cleanup
  • svn status        //view file status  in the current directory

How to use the Terminal in macOS ?

  • cd ~     // navigate to your Home folder
  • cd ../     //navigate to the previous folder
  • cd    path       // you can drag the Documents folder onto the Terminal window.
  • ls           //is the command for listing files
  • pwd     //view current path
  • mkdir foldername    //create a folder under the current path     like:mkdir test
  • touch filename      //create a file        like:touch readme.txt
  • open path
  • clear         // clear all content on the current window
  • du -sh *       //view the folder size

Continue reading “How to use the Terminal in macOS ?”

The use of mysql

The use of mysql ( mysql version:5.6.34 )

  • mysql -uusername -ppassword      //logon mysql           like:mysql -uroot -pmiPG2e8
  • create database databasename;      //create database     like:create database test;
  • show databases;     //view all databases
  • use databasename;     //change to current database     like:use test;
  • drop database databasename;     //delete database     like:drop database test;
  • show tables;     //view all tables in the current database
  • create table tablename (columnname datatype );      //create table    like:create table test(
    id int unsigned not null auto_increment primary key,
    name char(8) not null,
    sex char(4) not null,
    age tinyint unsigned not null,
    tel char(13) null default “-“);
  • drop table tablename ;      //delete table       like:drop table test;
  • alter table oldtablename rename newtablename ;    // rename table    like: alter table test rename test1;
  • desc tablename;        //view table info       like:desc test;
  • show full fields from tablename;    //show table detail
  • truncate table tablename;     //clear all data in the table    like:truncate table test;
  • select * from tablename where …;    //query all data in the table    like:select * from users where userId = ‘1’;
  • insert into tablename (columnname) values (‘value’) where … ;  //insert      like:insert into users (username,password) values (‘Jerry’,’12345678′) where userId =’1′;
  • update tablename set columnname = ‘value’ where … ;     //update     like:update users set username = ‘Jack’ where userId = ‘1’;
  • delete from tablename where … ;       //delete     like:delete from users where userId = ‘1’;

  • select version();     //view mysql version(In the login state)
  • show character set;         //show all character set for mysql
  • exit;      //exit mysql