2018-01-11 :-)
_ [Travis CI]はじめての Travis CI
「いまどきwwww Travis CI www 草www」という感じで 5 周遅れくらいですが使ってみました。はじめてなので /// みんな大好き世界よこんにちは。
レガシーおじさんなので C 言語で。travis のテストは 0 で pass、非0 で fail らしいのでひとまず 0 決め打ち。
#include <stdio.h>
int main(int ac, char** av)
{
	printf("hello travis!!\n");
	return 0;
}
.travis.yml も超絶簡単に。
language: c 
compiler:
  - gcc
script:
    gcc main.c -o main && ./main
ソースファイルに限らず何らかのファイルをリポジトリに push すると travis がトリガーされて、ビルドとテストが実行されます。(ログを眺めてると毎回 仮想環境を構築しているようでそのぶんの時間がかかります)
travis のリポジトリページでバッジへのリンクが取得できるので、github の README.md 等にリンクを書いておくとテスト結果が表示されます。わーい たーのしー
_ [curl]curl で github の release ファイルを取得する方法
-L も付けていけませんかね
— デコ (@Decors1215) January 11, 2018
curl -O -L https://github.com/mackerelio/mackerel-agent-plugins/releases/download/v0.42.0/mackerel-agent-plugins_0.42.0-1_all.deb
マニュアル嫁っていう数年前に投げたブーメランが戻ってきた。
       -L, --location
              (HTTP) If the server reports that the requested page has moved to a different location  (indicated  with  a  Location:
              header  and  a 3XX response code), this option will make curl redo the request on the new place. If used together with
              -i, --include or -I, --head, headers from all requested pages will be shown. When authentication is  used,  curl  only
              sends its credentials to the initial host. If a redirect takes curl to a different host, it won't be able to intercept
              the user+password. See also --location-trusted on how to change this. You can limit the amount of redirects to  follow
              by using the --max-redirs option.
[ツッコミを入れる]









