One Paragraph of project description goes here
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
package main | |
import "encoding/json" | |
// Unescape UTF-8 string | |
// e.g. convert "\u0e27\u0e23\u0e0d\u0e32" to "วรญา" | |
func UnescapeString(str string) (unescapedString string) { | |
json.Unmarshal([]byte(`"`+str+`"`), &unescapedString) | |
return | |
} |
We want to upload file to a server with POST HTTP request. We will use curl functions.
// data fields for POST request
$fields = array("f1"=>"value1", "another_field2"=>"anothervalue");
// files to upload
$filenames = array("/tmp/1.jpg", "/tmp/2.png");
Pip is a package manager of python. You can download Python
libraries from some Python
repositories like PyPI
. You can also download libraries from a git
repository. This is gonna be the issue to be explained in this article.
I don't like to memorize things all the time. So, I guess, I couldn't be working without internet :). Whenever I need to install some python libraries from a git repositories, I see a lot of way to do it. It is really confusing. This should be the reason why I can't memorize it. I can see how a very simple requirement is handled with to many confusing way. There shouldn't be to many way. Some of them is not working neither. At last, I decided to blog it.
As you may know, you can use two protocols which are http
and ssh
to do something on git
repositories. Using protocol ssh
instead of http
may provide some ease of use. Because of nature of ssh
, you can do something with your primary/public keys. So, you don't have to input your credentials all the time. But I'll be