Posts for: #Til

How to use Xcode 11’s Swift Package Manager in your project

Similar like Cocoapods or Carthage, you can use Swift Package Manager to manage the dependencies in your Cocoa project. With the latest Xcode 11, there is now a native support for Swift Package Manager for you to use it directly in your project. Adding a new package To add a new package with Swift Package Manager is really easy. Go to the following Xcode’s menu: File > Swift Packages > Add Package Dependency.
Read more

How to use Go Dep to Manage Dependencies

dep is a dependency management tool for golang. If you have work on other programming languages, dep is similar to npm, pod or pip. In simple words, it is a package manager to manage your project’s third party libraries. How to install it There’s a few ways to install dep. Personally, I prefer to install it with Homebrew To install it run: $~ brew install dep Initializing a project with dep To initialize it in your go project, go to your project directory and run the following
Read more

Viewing the git diff since the last git pull

To view the changes between your latest git pull $~ git pull origin $~ git diff @{1}.. @{n} means the n-th previous value of HEAD. You can refer the official docs on reflog Shortnames for more. p/s: I am currently trying to dissociate myself from becoming too dependent on SourceTree for daily git operations.
Read more