decadence

個人のメモ帳

SBT in Action

何か半額?だったし、SBT in Action - Manning買って出てる分まで読んだ。

  • sbtの基本(設定とかコンフィギュレーションとか)
  • inspect tree
  • internal vs. external
    • なるほど
  • managed vs. unmanaged
    • 今更感あるけど、なるほど
  • stateが回されてって、state.remainingCommands...
  • commandのパーサー、ヘルプコマンドの書き方
  • command vs. task
    • まだイマイチわからん
  • all でコマンドの並列実行
  • publishの仕方云々
  • Ivy と Maven
  • test->testとか
  • build.sbtBuild.scalaは好きな方使ったら良い

sbtの事知らずにplugin書いてたし、多分次はsbt自体をちゃんと読む。で、マクロで死ぬ。

後、Functional Programming in Scala - Manningも興味ある。

### internal vs external and so on - Internal vs. External - Internal refers to something sbt will find or create.  External to something obtained outside sbt, like using Ivy to resolve artifacts - internalがsbtが勝手に見つける方で、externalは外部tの - Managed vs. Unmanaged - Managed refers to something that is directly specified in the sbt build, like ivy dependencies.  Unmanaged refers to something that is automatically discovered by convention, like source files. - managedが手で追加する方で、unmanagedがsbtが勝手に見つける方 - include + exclude filters - All tasks which discover files on the file system support both an include and an exclude filter, configured on the task scope axis. - ファイル名とか隠しファイルとかのフィルターとか出来るやつ #### command vs task - Do I need to reload the build or alter settings in my script? - YES - write a command - Do I need to run tasks in a specific order? - YES - write a command - Do I need to alter the core sbt.State object? - YES - write a task. > As a rule of thumb, commands are generally used much less than input task, say a ratio of 2:1.   This means a majority of your build will be settings/tasks, with a fraction as input tasks and a small portion being commands, with the release command usually being the only custom command. > In addition, there exists and sbt-release plugin which provides a configurable release command for usage.   For most projects, this plugin should be sufficient for automating release scripts, but there are instances where it is not enough and a custom command needs to be created.  > Now that we’ve scripted our release process, let’s actually look into some more robust ways to package the preowned kittens project when we release.”
広告を非表示にする