Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenlautier committed Dec 5, 2019
2 parents 5672dc1 + 31597e0 commit b78c330
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 14 deletions.
7 changes: 1 addition & 6 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,13 @@ jobs:
- run:
name: Check if branch is publishable
command: |
if ! ([ $CIRCLE_BRANCH = "develop" ] || [ $CIRCLE_BRANCH = "master" ]); then
if ! ([ $CIRCLE_BRANCH = "master" ] || [[ "$CIRCLE_BRANCH" =~ ^(([0-9]+|\.)+x)$ ]]); then
echo "Non-publishable branch; finishing build..."
circleci step halt
fi
- deploy:
name: Publish NuGet
command: |
if [ "$CIRCLE_BRANCH" != "master" ]; then
echo -e "\e[33m Branch does not publish -- exit!"
exit
fi
export SKETCH7_NUGET_API_KEY=$API_KEY
npm run publish:dev
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

### Features

- **headers:** add several utility methods
- **headers:** add several utility methods
- `ctor IDictionary<string, StringValues>`
- `Add(string, StringValues)`
- `Remove(string)`
Expand Down
13 changes: 9 additions & 4 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -11,23 +11,28 @@
<Product>FluentlyHttpClient</Product>
<Copyright>© sketch7. All rights reserved.</Copyright>
<PackageProjectUrl>https://github.com/sketch7/FluentlyHttpClient</PackageProjectUrl>
<PackageIconUrl>https://avatars0.githubusercontent.com/u/16617196?v=3&amp;s=200</PackageIconUrl>
<PackageTags>httpclient fluentapi fluenthttp graphql graphqlclient</PackageTags>
<PackageReleaseNotes></PackageReleaseNotes>
<RepositoryUrl>https://github.com/sketch7/FluentlyHttpClient.git</RepositoryUrl>
<RepositoryType>git</RepositoryType>
<!-- Note: quite nice to have but since we dont really use, they will simply slow down CI
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<PackageIcon>logo188x188.png</PackageIcon>
<IncludeSymbols>true</IncludeSymbols>
<IncludeSource>true</IncludeSource> -->
<IncludeSource>true</IncludeSource>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
</PropertyGroup>

<ItemGroup>
<None Include="$(SourceRoot)assets/logo188x188.png" Pack="true" Visible="false" PackagePath="/" />
</ItemGroup>

<!-- Common compile parameters -->
<PropertyGroup>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<NoWarn>$(NoWarn);1701;1702;1705;1591</NoWarn>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<LangVersion>latest</LangVersion>
<LangVersion>8.0</LangVersion>
<Nullable>enable</Nullable>
</PropertyGroup>

<PropertyGroup>
Expand Down
5 changes: 4 additions & 1 deletion docs/RELEASE-WORKFLOW.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@
In order to release follow the following procedure.

- Create branch e.g. `feature/xyz`.. *onces changes are ready...*
- Create a PR from `feature/xyz` to `master`

## Stable Versions
- Create PR to version branch `3.x`
- Update version within `package.json`
- Update `CHANGELOG.md`
- Create a PR from `feature/xyz` to `master`
- Once merged it will auto `publish` and `git tag`
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@sketch7/fluently-http-client",
"version": "3.7.2",
"version": "3.7.3",
"versionSuffix": "",
"scripts": {
"pack": "bash ./tools/pack.sh",
Expand Down
2 changes: 1 addition & 1 deletion tools/publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ DIR=`dirname "${THIS}"` # This directory path
. "$DIR/version-builder.sh"

err(){
echo -e "\e[31m $* \e[0m" >>/dev/stderr
echo -e "\e[31m $* \e[0m" >&2
}

echo -e "\e[36m ---- Publish ---- \e[39m"
Expand Down
4 changes: 4 additions & 0 deletions tools/version-builder.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ if [ -z "$PACKAGE_VERSION_SUFFIX" ] && [ -z "$CI" ]; then
PACKAGE_VERSION_SUFFIX=dev
fi

if [ $CIRCLE_BRANCH = "master" ] ; then
PACKAGE_VERSION_SUFFIX=dev$CIRCLE_BUILD_NUM
fi

if [ -n "$PACKAGE_VERSION_SUFFIX" ]; then
VERSION=$VERSION-$PACKAGE_VERSION_SUFFIX
fi
Expand Down

0 comments on commit b78c330

Please sign in to comment.