yuchesc.github.io

MEMO command list

Change DNS on Ubuntu 18.04

python3 -m venv [name]

Make virtual env for python3

python3 -m venv [name]

sbt tgz instead of ZIP

sbt packageZipTarball
sbt universal:package-zip-tarball

Publish maven central

sbt +publishSigned

Go to https://oss.sonatype.org/

Close and Release.

Play new app

sbt new playframework/play-scala-seed.g8

return inserted ID on slick3

Items returning Items.map(_.id) += item

Get current directory on bash

script_dir=$(cd $(dirname $(readlink $0 || echo $0));pwd -P)

git

make branch

git branch develop

change branch

git checkout develop

undo add

git rm --cached [file]

delete local branch

ex: use_ftp branch

git branch -d use_ftp

delete remote branch

git push origin :use_ftp

add tag

git tag v1.0

push tag

git push origin v1.0

modify commit log

git commit --amend

Restore deleted file

git checkout HEAD -- <filename>

Systemd list auto starting units

systemctl list-unit-files|grep enabled

Sphinx

 :doc:`filename`

change power shell policy on windows

Run as an administrator.

Set-ExecutionPolicy RemoteSigned