-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #149 from Comcast/release/2.4.0
Release 2.4.0
- Loading branch information
Showing
82 changed files
with
1,531 additions
and
326 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
name: Generate Release | ||
run-name: Generate Release ${{ fromJSON(inputs.major) }}.${{ fromJSON(inputs.minor) }}.${{ fromJSON(inputs.patch) }} | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
major: | ||
description: 'Major version' | ||
required: true | ||
default: '1' | ||
type: choice | ||
options: | ||
- '1' | ||
- '2' | ||
minor: | ||
description: 'Minor version' | ||
required: true | ||
type: number | ||
patch: | ||
description: 'Patch version' | ||
required: true | ||
type: number | ||
|
||
jobs: | ||
bump-version-and-raise-pr: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
pull-requests: write | ||
env: | ||
version: ${{ fromJSON(inputs.major) }}.${{ fromJSON(inputs.minor) }}.${{ fromJSON(inputs.patch) }} | ||
branch: ${{ inputs.major == 2 && 'develop' || 'develop_1.x' }} | ||
target: ${{ inputs.major == 2 && 'main' || 'main_1.x' }} | ||
steps: | ||
- name: Check minor has no decimals | ||
run: ${{ !contains(fromJSON(inputs.minor), '.') }} | ||
|
||
- name: Check patch has no decimals | ||
run: ${{ !contains(fromJSON(inputs.patch), '.') }} | ||
|
||
- name: Checkout ${{ env.target }} | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ env.target }} | ||
fetch-depth: 0 | ||
|
||
- name: Ensure tag does not exist | ||
run: | | ||
if git show-ref --tags --verify --quiet "refs/tags/$version"; then | ||
echo "::error::Tag $version exists" && exit 1 | ||
else | ||
echo "Tag $version does not exist" | ||
fi | ||
- name: Ensure branch does not exist | ||
run: | | ||
if git show-ref --verify --quiet "refs/remotes/origin/release/$version"; then | ||
echo "::error::Release branch release/$version exists" && exit 1 | ||
else | ||
echo "Release branch release/$version does not exist" | ||
fi | ||
- name: Merge in ${{ env.branch }} | ||
run: | | ||
git config user.name github-actions | ||
git config user.email [email protected] | ||
git merge origin/${{ env.branch }} | ||
- name: Update version in txt file | ||
run: sed -i "s/[0-9]\{1,\}\.[0-9]\{1,\}\.[0-9]\{1,\}/$version/" ./mambaSharedFramework/Resources/version.txt | ||
|
||
- name: Update version in xcodeproj file | ||
run: sed -i "s/MARKETING_VERSION = [0-9]\{1,\}\.[0-9]\{1,\}\.[0-9]\{1,\};/MARKETING_VERSION = $version;/" ./mamba.xcodeproj/project.pbxproj | ||
|
||
- name: Update version in podspec file | ||
run: sed -i "s/= \"[0-9]\{1,\}\.[0-9]\{1,\}\.[0-9]\{1,\}\"/= \"$version\"/" ./mamba.podspec | ||
|
||
- name: Create pull request | ||
uses: peter-evans/create-pull-request@v7 | ||
with: | ||
title: Release ${{ env.version }} | ||
commit-message: Bump version to ${{ env.version }} | ||
branch: release/${{ env.version }} | ||
body: | | ||
Automated version bump to ${{ env.version }} generated by [create-pull-request][1]. | ||
[1]: https://github.com/peter-evans/create-pull-request |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
name: Publish Release | ||
on: | ||
push: | ||
branches: | ||
- 'main' | ||
- 'main_1.x' | ||
|
||
jobs: | ||
get-version: | ||
name: Get version for release | ||
runs-on: ubuntu-latest | ||
outputs: | ||
version: ${{ steps.version.outputs.version }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- id: version | ||
run: echo "version=`cat ./mambaSharedFramework/Resources/version.txt`" >> "$GITHUB_OUTPUT" | ||
|
||
publish-release: | ||
name: Publish release ${{ needs.get-version.outputs.version }} | ||
runs-on: ubuntu-latest | ||
needs: get-version | ||
permissions: | ||
contents: write | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Create release | ||
uses: elgohr/Github-Release-Action@v5 | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
title: ${{ needs.get-version.outputs.version }} | ||
tag: ${{ needs.get-version.outputs.version }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
// swift-tools-version:5.3 | ||
// The swift-tools-version declares the minimum version of Swift required to build this package. | ||
// | ||
// Package.swift | ||
// mamba | ||
// | ||
// Copyright © 2020 Comcast Cable Communications Management, LLC | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
// | ||
|
||
import PackageDescription | ||
|
||
let package = Package( | ||
name: "mamba", | ||
products: [ | ||
.library( | ||
name: "mamba", | ||
targets: ["mamba"] | ||
) | ||
], | ||
targets: [ | ||
.target( | ||
name: "mamba", | ||
dependencies: [.target(name: "HLSObjectiveC")], | ||
path: "mambaSharedFramework", | ||
exclude: [ | ||
"HLS ObjectiveC", | ||
"PlaylistParserError", | ||
"mamba.h" | ||
], | ||
resources: [ | ||
.process("Resources") | ||
] | ||
), | ||
.target( | ||
name: "PlaylistParserError", | ||
path: "mambaSharedFramework/PlaylistParserError" | ||
), | ||
.target( | ||
name: "HLSObjectiveC", | ||
dependencies: ["PlaylistParserError"], | ||
path: "mambaSharedFramework/HLS ObjectiveC", | ||
exclude: [ | ||
"PrototypeRapidParseArray.include", | ||
"RapidParser_LookingForEForEXTINFState_ParseArray.include", | ||
"RapidParser_LookingForEForEXTState_ParseArray.include", | ||
"RapidParser_LookingForHashForEXTINFState_ParseArray.include", | ||
"RapidParser_LookingForHashForEXTState_ParseArray.include", | ||
"RapidParser_LookingForIForEXTINFState_ParseArray.include", | ||
"RapidParser_LookingForNewlineForEXTINFState_ParseArray.include", | ||
"RapidParser_LookingForNewLineForEXTState_ParseArray.include", | ||
"RapidParser_LookingForNewLineForHashState_ParseArray.include", | ||
"RapidParser_LookingForNForEXTINFState_ParseArray.include", | ||
"RapidParser_LookingForTForEXTINFState_ParseArray.include", | ||
"RapidParser_LookingForXForEXTINFState_ParseArray.include", | ||
"RapidParser_LookingForXForEXTState_ParseArray.include", | ||
"RapidParser_ScanningState_ParseArray.include", | ||
] | ||
) | ||
] | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.