Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TC: Add open-close block helpers #1049

Merged
merged 1 commit into from
Dec 22, 2015
Merged

Conversation

tolu
Copy link
Contributor

@tolu tolu commented Dec 21, 2015

Added helper methods for TeamCity blocks

Usage

Target "MyTarget" (fun _ ->
  sendOpenBlock "MyTarget"
  // target code here
  sendCloseBlock "MyTarget"
)

This nifty little thing gets you from this:

Before

to this (targets in an expandable tree view):

After

Futures
As a next step it would be awesome to use this feature by default in the target output (when running in TeamCity) instead of going the long way round and polluting every target with sendOpenBlock / sendCloseBlock.

forki added a commit that referenced this pull request Dec 22, 2015
TC: Add open-close block helpers
@forki forki merged commit 1650c0e into fsprojects:master Dec 22, 2015
@forki
Copy link
Member

forki commented Dec 22, 2015

thx

@dahlbyk
Copy link

dahlbyk commented Dec 22, 2015

Would it make sense to model this as IDisposable?

Target "MyTarget" (fun _ ->
  use sendBlock "MyTarget"
  // target code here
)

@forki
Copy link
Member

forki commented Dec 22, 2015

I think you should not use this in user code. It should be used in target and task helpers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants