<commit_before># gitversion will change the version number
version: x-{build}

# branches to build
branches:
  # blacklist
  except:
    - gh-pages

configuration: Release
os: Visual Studio 2017

init:
  - git config --global core.autocrlf input
  - git config --global credential.helper store
  - ps: Add-Content "$env:USERPROFILE\.git-credentials" "https://$($env:git_token):x-oauth-basic@github.com`n"
  - git config --global user.email "<EMAIL>"
  - git config --global user.name "Appveyor CI"

cache:
  - packages -> **\packages.config      # preserve "packages" directory in the root of build folder but will reset it if packages.config is modified

environment:
  COVERALLS_REPO_TOKEN:
    secure: <KEY>
  git_token:
    secure: <KEY>
  snk_secret:
    secure: <KEY>

# tools we need for bulding/testing/deploying
install:
  - choco install gitversion.portable -pre -y
  - nuget update -self
  #- npm install gh-pages -g

#  - nuget install secure-file -ExcludeVersion
#  - if defined snk_secret secure-file\tools\secure-file -decrypt src\ipfs.ci.snk.enc -secret %snk_secret% -out src\ipfs.dev.snk
  - choco install ipfs
  - ipfs init
  - ps: Start-Process -FilePath "ipfs.exe" -ArgumentList "daemon"

# gitversion will change the assembly info
pull_requests:
  do_not_increment_build_number: true

before_build:
  - nuget restore
  - ps: gitversion /output buildserver /updateAssemblyInfo >gitversion.log

build_script:
  - dotnet build -c %CONFIGURATION% -p:Version=%GitVersion_MajorMinorPatch% -p:AssemblyVersion=%GitVersion_MajorMinorPatch%
  - dotnet pack -c %CONFIGURATION% --no-build --no-restore -p:Version=%GitVersion_MajorMinorPatch% -p:AssemblyVersion=%GitVersion_MajorMinorPatch%

after_build:
  - cmd: appveyor PushArtifact "src\bin\%CONFIGURATION%\Ipfs.Core.%GitVersion_MajorMinorPatch%.nupkg"
# Build documentation in doc\_site
#  - tools\docfx\docfx doc\docfx.json
#  - if defined git_token gh-pages -d doc\_site -m "new docs %GitVersion_FullSemVer%"

test_script:
  - dotnet test -c %CONFIGURATION% --no-build --no-restore test

after_test: 
# Generate coverage report
    - packages\OpenCover.4.6.519\tools\OpenCover.Console.exe 
        -register:user -filter:"+[Ipfs.Api*]* -[*Tests]*" 
        -target:"c:\Program Files\dotnet\dotnet.exe" 
        -targetargs:"test -c Release --no-build --no-restore test" 
        -output:coverage.xml  
        -mergeoutput 
        -hideskipped:File 
        -oldStyle 
    - if defined COVERALLS_REPO_TOKEN 
        packages\coveralls.net.0.6.0\tools\csmacnz.coveralls.exe 
        --opencover -i ./coverage.xml --useRelativePaths --serviceName appveyor --jobId %APPVEYOR_BUILD_NUMBER%

# publish NuGet package on tag build
nuget:
  account_feed: true
  project_feed: true
  disable_publish_on_pr: true
deploy:
- provider: NuGet<commit_msg>chore(ci): copy and paste error<commit_after># gitversion will change the version number
version: x-{build}

# branches to build
branches:
  # blacklist
  except:
    - gh-pages

configuration: Release
os: Visual Studio 2017

init:
  - git config --global core.autocrlf input
  - git config --global credential.helper store
  - ps: Add-Content "$env:USERPROFILE\.git-credentials" "https://$($env:git_token):x-oauth-basic@github.com`n"
  - git config --global user.email "<EMAIL>"
  - git config --global user.name "Appveyor CI"

cache:
  - packages -> **\packages.config      # preserve "packages" directory in the root of build folder but will reset it if packages.config is modified

environment:
  COVERALLS_REPO_TOKEN:
    secure: <KEY>
  git_token:
    secure: <KEY>
  snk_secret:
    secure: <KEY>

# tools we need for bulding/testing/deploying
install:
  - choco install gitversion.portable -pre -y
  - nuget update -self
  #- npm install gh-pages -g

#  - nuget install secure-file -ExcludeVersion
#  - if defined snk_secret secure-file\tools\secure-file -decrypt src\ipfs.ci.snk.enc -secret %snk_secret% -out src\ipfs.dev.snk
  - choco install ipfs
  - ipfs init
  - ps: Start-Process -FilePath "ipfs.exe" -ArgumentList "daemon"

# gitversion will change the assembly info
pull_requests:
  do_not_increment_build_number: true

before_build:
  - nuget restore
  - ps: gitversion /output buildserver /updateAssemblyInfo >gitversion.log

build_script:
  - dotnet build -c %CONFIGURATION% -p:Version=%GitVersion_MajorMinorPatch% -p:AssemblyVersion=%GitVersion_MajorMinorPatch%
  - dotnet pack -c %CONFIGURATION% --no-build --no-restore -p:Version=%GitVersion_MajorMinorPatch% -p:AssemblyVersion=%GitVersion_MajorMinorPatch%

after_build:
  - cmd: appveyor PushArtifact "src\bin\%CONFIGURATION%\Ipfs.Api.%GitVersion_MajorMinorPatch%.nupkg"
# Build documentation in doc\_site
#  - tools\docfx\docfx doc\docfx.json
#  - if defined git_token gh-pages -d doc\_site -m "new docs %GitVersion_FullSemVer%"

test_script:
  - dotnet test -c %CONFIGURATION% --no-build --no-restore test

after_test: 
# Generate coverage report
    - packages\OpenCover.4.6.519\tools\OpenCover.Console.exe 
        -register:user -filter:"+[Ipfs.Api*]* -[*Tests]*" 
        -target:"c:\Program Files\dotnet\dotnet.exe" 
        -targetargs:"test -c Release --no-build --no-restore test" 
        -output:coverage.xml  
        -mergeoutput 
        -hideskipped:File 
        -oldStyle 
    - if defined COVERALLS_REPO_TOKEN 
        packages\coveralls.net.0.6.0\tools\csmacnz.coveralls.exe 
        --opencover -i ./coverage.xml --useRelativePaths --serviceName appveyor --jobId %APPVEYOR_BUILD_NUMBER%

# publish NuGet package on tag build
nuget:
  account_feed: true
  project_feed: true
  disable_publish_on_pr: true
deploy:
- provider: NuGet
{'fraction_non_alphanumeric': 0.11245336649493694, 'fraction_numerical': 0.004263634748623201, 'mean_word_length': 3.5003996802557955, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 15, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 4}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '47546', 'n_tokens_mistral': 1971, 'n_tokens_neox': 1878, 'n_words': 465}