LoginSignup
0
0

More than 3 years have passed since last update.

メモ用

Last updated at Posted at 2019-09-20

EC2のインスタンスの作成
apach, nginx, phpのインストール
RDS(postres)
route

docker

コンテナに入る

docker exec -it コンテナ名など bash

コンテナの再開

docker start コンテナ名

docker-compose exec app php artisan migrate:refresh
docker-compose exec app php artisan migrate:refresh --seed

git

リモートレポジトリの確認
git remote -v

【ファイル名】をインデックスに追加
git add 【ファイル名】

インデックスに追加した内容の差分確認
git diff --cached

コミットする
git commit -v

コミットされているかどうかの確認
git log

コミットのプッシュ
git push origin master

ブランチの作成
git checkout -b DATE200106

ブランチ一覧の表示
git branch -a

作成したブランチをリモートに登録
git push -u origin DATE200106

現在、チェックアウトしているブランチのコミットIDを調べる

git show -s --format=%H
git log -n 1 --format=%H

コミットログを表示する

git log -n 10 --date=short --no-merges --pretty=format:"%cd %s %h (@%cn) "

コミットの差分を確認する

git diff 【コミットID】 【コミットID】

インデックスをHEADの状態へ戻す

git reset .

gitコマンドの簡略化

cron

crontab -e

(minutes) (hour) (day) (month) (week)
0 9 * * * bash 【パス】/today_task.bash

mkdir

mkdir /Users/work/Documents/work/`date '+%y%m%d'`

laravelの git clone 後の実行コマンド

git clone 【git laravel レポジトリ】 【ディレクトリを指定する】
composer install
cp .env.example .env
php artisan key:generate

php artisan migrate:fresh
php artisan migrate:refresh
php artisan migrate:rollback
php artisan migrate:rollback --step=1
php artisan migrate

chatwork api

curl -X POST -H "X-ChatWorkToken: 【トークン】" \
-d "body=本日の日付は"`date '+%y%m%d'`"&self_unread=0" \
"https://api.chatwork.com/v2/rooms/【room_id】/messages"

linux コマンド

https://parashuto.com/rriver/tools/mac-command-line-basics
ls -l
cd
cp
mv
rm
cat
pwd
touch
mkdir -p
find . -name "*.【ファイル拡張子】" -exec grep -H -i 【調べる文字列】 {} \;
find . -type f -mtime +30 | xargs tar zcvf

// Jupyter Notebookの実行
jupyter notebook

~ = shift + Pn

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0