Skip to content

Commit

Permalink
PubNub Swift Chat SDK 0.9.0 (#8)
Browse files Browse the repository at this point in the history
feat(message): add Message Draft feature
fix(entities): return nil for hard delete operations
fix(configuration): add missing reactionsActionName property
  • Loading branch information
jguz-pubnub authored Nov 6, 2024
1 parent 4cee3a3 commit b7e5d70
Show file tree
Hide file tree
Showing 54 changed files with 2,018 additions and 346 deletions.
2 changes: 2 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
* @jguz-pubnub @parfeon @wkal-pubnub @marcin-cebo
README.md @techwritermat @kazydek @jguz-pubnub @parfeon @wkal-pubnub @marcin-cebo
44 changes: 44 additions & 0 deletions .github/workflows/commands-handler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Commands processor

on:
issue_comment:
types: [created]
defaults:
run:
shell: bash

jobs:
process:
name: Process command
if: github.event.issue.pull_request && endsWith(github.repository, '-private') != true
runs-on:
group: organization/Default
steps:
- name: Check referred user
id: user-check
env:
CLEN_BOT: ${{ secrets.CLEN_BOT }}
run: echo "expected-user=${{ startsWith(github.event.comment.body, format('@{0} ', env.CLEN_BOT)) }}" >> $GITHUB_OUTPUT
- name: Regular comment
if: steps.user-check.outputs.expected-user != 'true'
run: echo -e "\033[38;2;19;181;255mThis is regular commit which should be ignored.\033[0m"
- name: Checkout repository
if: steps.user-check.outputs.expected-user == 'true'
uses: actions/checkout@v4
with:
token: ${{ secrets.GH_TOKEN }}
- name: Checkout release actions
if: steps.user-check.outputs.expected-user == 'true'
uses: actions/checkout@v4
with:
repository: pubnub/client-engineering-deployment-tools
ref: v1
token: ${{ secrets.GH_TOKEN }}
path: .github/.release/actions
- name: Process changelog entries
if: steps.user-check.outputs.expected-user == 'true'
uses: ./.github/.release/actions/actions/commands
with:
token: ${{ secrets.GH_TOKEN }}
listener: ${{ secrets.CLEN_BOT }}
jira-api-key: ${{ secrets.JIRA_API_KEY }}
58 changes: 58 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Automated product release

on:
pull_request:
branches: [master]
types: [closed]

jobs:
check-release:
name: Check release required
if: github.event.pull_request.merged && endsWith(github.repository, '-private') != true
runs-on:
group: organization/Default
outputs:
release: ${{ steps.check.outputs.ready }}
steps:
- name: Checkout actions
uses: actions/checkout@v4
with:
repository: pubnub/client-engineering-deployment-tools
ref: v1
token: ${{ secrets.GH_TOKEN }}
path: .github/.release/actions
- id: check
name: Check pre-release completed
uses: ./.github/.release/actions/actions/checks/release
with:
token: ${{ secrets.GH_TOKEN }}
publish:
name: Publish package
needs: check-release
if: needs.check-release.outputs.release == 'true'
runs-on:
group: macos-arm-gh
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
ref: master
token: ${{ secrets.GH_TOKEN }}
- name: Checkout actions
uses: actions/checkout@v4
with:
repository: pubnub/client-engineering-deployment-tools
ref: v1
token: ${{ secrets.GH_TOKEN }}
path: .github/.release/actions
- name: Setup Ruby 3.2.2
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.2.2
bundler-cache: true
- name: Create Release
uses: ./.github/.release/actions/actions/services/github-release
with:
token: ${{ secrets.GH_TOKEN }}
jira-api-key: ${{ secrets.JIRA_API_KEY }}
last-service: true
12 changes: 12 additions & 0 deletions .github/workflows/release/versions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
".pubnub.yml": [
{ "pattern": "^version: \"(.+)\"$", "cleared": true },
{ "pattern": "\/refs\/tags\/((\\d+\\.?){2,}(-[a-zA-Z]+(.\\d+)?)?)\\.zip", "cleared": true }
],
"PubNubSwiftChatSDK.xcodeproj/project.pbxproj": [
{ "pattern": "MARKETING_VERSION = ([0-9]+\\.[0-9]+\\.[0-9]+(\\.[0-9]+)?);", "cleared": true }
],
"Sources/Miscellaneous/Constants.swift": [
{ "pattern": "pubNubSwiftChatSDKVersion\\:.+\"((\\d+\\.?){2,})\"$", "cleared": true }
]
}
75 changes: 75 additions & 0 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
name: Tests

on:
push:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
defaults:
run:
shell: bash

env:
LANG: en_US.UTF-8
LANGUAGE: en_US.UTF-8
LC_ALL: en_US.UTF-8
LC_CTYPE: en_US.UTF-8

jobs:
tests:
name: Integration tests
env:
SDK_PUB_KEY: ${{ secrets.SDK_PUB_KEY }}
SDK_SUB_KEY: ${{ secrets.SDK_SUB_KEY }}
SDK_PAM_SUB_KEY: ${{ secrets.SDK_PAM_SUB_KEY }}
SDK_PAM_PUB_KEY: ${{ secrets.SDK_PAM_PUB_KEY }}
SDK_PAM_SEC_KEY: ${{ secrets.SDK_PAM_SEC_KEY }}
runs-on:
group: macos-arm-gh
strategy:
matrix:
environment: [iOS]
timeout-minutes: 17
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
token: ${{ secrets.GH_TOKEN }}
clean: true
fetch-depth: 0
- name: Checkout actions
uses: actions/checkout@v4
with:
repository: pubnub/client-engineering-deployment-tools
ref: v1
token: ${{ secrets.GH_TOKEN }}
path: .github/.release/actions
- name: Setup Ruby 3.2.2
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.2.2
bundler-cache: true
- name: Clear SPM and DerivedData caches
run: |
rm -rf "$HOME/Library/Caches/org.swift.swiftpm"
rm -rf ~/Library/Developer/Xcode/DerivedData
rm -rf ~/.swiftpm
- name: Clear build cache
run: rm -rf .build
- name: Pre-load simulators list
if: ${{ matrix.environment != 'macOS' }}
run: xcrun simctl list -j
- name: Run ${{ matrix.environment }} integration tests
run: bundle exec fastlane test --env $(echo ${{ matrix.environment }} | tr '[:upper:]' '[:lower:]')
- name: Cancel workflow runs for commit on error
if: failure()
uses: ./.github/.release/actions/actions/utils/fast-jobs-failure
all-tests:
name: Tests
needs: [tests]
runs-on:
group: organization/Default
steps:
- name: Tests summary
run: echo -e "\033[38;2;95;215;0m\033[1mAll tests successfully passed"
76 changes: 76 additions & 0 deletions .github/workflows/run-validations.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
name: Validations

on:
push:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
defaults:
run:
shell: bash

env:
LANG: en_US.UTF-8
LANGUAGE: en_US.UTF-8
LC_ALL: en_US.UTF-8

jobs:
pubnub-yml:
name: "Validate .pubnub.yml"
runs-on:
group: organization/Default
steps:
- name: Checkout project
uses: actions/checkout@v4
- name: Checkout validator action
uses: actions/checkout@v4
with:
repository: pubnub/client-engineering-deployment-tools
ref: v1
token: ${{ secrets.GH_TOKEN }}
path: .github/.release/actions
- name: "Run '.pubnub.yml' file validation"
uses: ./.github/.release/actions/actions/validators/pubnub-yml
with:
token: ${{ secrets.GH_TOKEN }}
- name: Cancel workflow runs for commit on error
if: failure()
uses: ./.github/.release/actions/actions/utils/fast-jobs-failure
package-managers-validation:
name: Validate package managers
runs-on:
group: macos-arm-gh
strategy:
matrix:
managers: [Swift Package Manager]
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
token: ${{ secrets.GH_TOKEN }}
- name: Checkout actions
uses: actions/checkout@v4
with:
repository: pubnub/client-engineering-deployment-tools
ref: v1
token: ${{ secrets.GH_TOKEN }}
path: .github/.release/actions
- name: Setup Ruby 3.2.2
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.2.2
bundler-cache: true
- name: ${{ matrix.managers }} validation
run: bundle exec fastlane lint_$(echo ${{ matrix.managers }} | tr '[:upper:]' '[:lower:]' | tr ' ' '_')
- name: Cancel workflow runs for commit on error
if: failure()
uses: ./.github/.release/actions/actions/utils/fast-jobs-failure
all-validations:
name: Validations
needs: [pubnub-yml, package-managers-validation]
runs-on:
group: organization/Default
steps:
- name: Validations summary
run: echo -e "\033[38;2;95;215;0m\033[1mAll validations passed"
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,10 @@ playground.xcworkspace
# Add this line if you want to avoid checking in source code from Swift Package Manager dependencies.
Packages/
Package.pins
Package.resolved
PubNubSwiftChatSDK.xcworkspace/xcshareddata/swiftpm
.swiftpm
.build
PubNubSwiftChatSDK.xcworkspace/xcshareddata/swiftpm

# CocoaPods
#
Expand Down
65 changes: 65 additions & 0 deletions .pubnub.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
---
name: swift-chat-sdk
scm: github.com/pubnub/swift-chat-sdk
version: "0.9.0"
schema: 1
changelog:
- date: 2024-11-06
version: 0.9.0
changes:
- type: feature
text: "Add Message Draft feature"
- type: bug
text: "Return nil for hard delete operations"
- type: bug
text: "Add missing reactionsActionName property"
- date: 2024-10-24
version: 0.8.2
changes:
- type: bug
text: "Use kmp-chat dependency without pubnub-kotlin submodule"
- date: 2024-10-22
version: 0.8.1
changes:
- type: bug
text: "Fix dependency issues for kmp-chat and its submodules"
- date: 2024-09-25
version: 0.8.0
changes:
- type: feature
text: "Initial Swift Chat SDK release"
sdks:
- full-name: PubNub Swift Chat SDK
short-name: PubNub Swift Chat SDK
artifacts:
- artifact-type: api-client
language: Swift
tier: 1
tags:
- Desktop
- Mobile
source-repository: https://github.com/pubnub/swift-chat-sdk
documentation: https://github.com/pubnub/swift-chat-sdk
distributions:
- distribution-type: source
distribution-repository: GitHub release
package-name: PubNubSwiftChatSDK
location: https://github.com/pubnub/swift-chat-sdk/archive/refs/tags/0.9.0-dev.zip
supported-platforms:
supported-operating-systems:
iOS:
runtime-version:
- Swift 5.x
minimum-os-version:
- iOS 14.0
maximum-os-version:
- iOS 18.0.1
target-architecture:
- arm64
target-devices:
- iPhone
- iPad
supported-platforms:
- version: PubNub Swift Chat SDK
platforms:
- iOS 14.0 or higher
4 changes: 4 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
source "https://rubygems.org"

gem "fastlane", '2.225.0'
gem 'rexml', '3.3.8'
Loading

0 comments on commit b7e5d70

Please sign in to comment.