<commit_before>version: 1.0.{build}

image: Visual Studio 2017

branches:
  only:
  - master
  
skip_tags: true

environment:
  nodejs_version: 6
  DOCKER_USER:
    secure: SWa6ANux+qBasg+rV9s1ow==
  DOCKER_PASS:
    secure: 4qfqj51DHaNYA6o4RcmH9g==

install:
  - ps: Install-Product node 6

build_script:
  - cd src/Squidex
  - npm i
  - npm run build:copy
  - npm run build
  - cd ../..
  - dotnet restore
  - dotnet publish src/Squidex/Squidex.csproj -o %APPVEYOR_BUILD_FOLDER%/release -c  Release
  - docker build %APPVEYOR_BUILD_FOLDER%/release -t squidex/squidex:%APPVEYOR_BUILD_VERSION% -t squidex/squidex:latest

test_script:
  - dotnet test tests/Squidex.Infrastructure.Tests/Squidex.Infrastructure.Tests.csproj
  - dotnet test tests/Squidex.Domain.Apps.Core.Tests/Squidex.Domain.Apps.Core.Tests.csproj
  - dotnet test tests/Squidex.Domain.Apps.Read.Tests/Squidex.Domain.Apps.Read.Tests.csproj
  - dotnet test tests/Squidex.Domain.Apps.Write.Tests/Squidex.Domain.Apps.Write.Tests.csproj
  - dotnet test tests/Squidex.Domain.Users.Tests/Squidex.Domain.Users.Tests.csproj
  - cd src/Squidex
  - npm run test:coverage

before_deploy:
  - docker login -u="%DOCKER_USER%" -p="%DOCKER_PASS%"
 
deploy:
  - provider: GitHub
    auth_token:
      <KEY>
    artifact: release.zip

after_deploy:
  - docker push squidex/squidex:latest
  - docker push squidex/squidex:%APPVEYOR_BUILD_VERSION%<commit_msg>Deployment Commands merged<commit_after>version: 1.0.{build}

image: Visual Studio 2017

branches:
  only:
  - master
  
skip_tags: true

environment:
  nodejs_version: 6
  DOCKER_USER:
    secure: SWa6ANux+qBasg+rV9s1ow==
  DOCKER_PASS:
    secure: 4qfqj51DHaNYA6o4RcmH9g==

install:
  - ps: Install-Product node 6

build_script:
  - cd src/Squidex
  - npm i
  - npm run build:copy
  - npm run build
  - cd ../..
  - dotnet restore
  - dotnet publish src/Squidex/Squidex.csproj -o %APPVEYOR_BUILD_FOLDER%/release -c  Release
  - docker build %APPVEYOR_BUILD_FOLDER%/release -t squidex/squidex:%APPVEYOR_BUILD_VERSION% -t squidex/squidex:latest

test_script:
  - dotnet test tests/Squidex.Infrastructure.Tests/Squidex.Infrastructure.Tests.csproj
  - dotnet test tests/Squidex.Domain.Apps.Core.Tests/Squidex.Domain.Apps.Core.Tests.csproj
  - dotnet test tests/Squidex.Domain.Apps.Read.Tests/Squidex.Domain.Apps.Read.Tests.csproj
  - dotnet test tests/Squidex.Domain.Apps.Write.Tests/Squidex.Domain.Apps.Write.Tests.csproj
  - dotnet test tests/Squidex.Domain.Users.Tests/Squidex.Domain.Users.Tests.csproj
  - cd src/Squidex
  - npm run test:coverage
 
deploy:
  - provider: GitHub
    auth_token:
      <KEY>
    artifact: release.zip

after_deploy:
  - cmd: >-
    docker login -u="%DOCKER_USER%" -p="%DOCKER_PASS%"
    docker push squidex/squidex:latest
    docker push squidex/squidex:%APPVEYOR_BUILD_VERSION%
{'fraction_non_alphanumeric': 0.10949164592961251, 'fraction_numerical': 0.012086740135087096, 'mean_word_length': 3.69, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, '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': '2037511', 'n_tokens_mistral': 1212, 'n_tokens_neox': 1120, 'n_words': 187}