Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

6.3.1b1 #1057

Merged
merged 23 commits into from
May 2, 2024
Merged

6.3.1b1 #1057

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
bf6f55b
--- 899 ---
tmolitor-stud-tu Apr 29, 2024
4d06a68
Nicer output when creating a release
tmolitor-stud-tu Apr 29, 2024
8acf65b
Fix flickering of default background image (Tie_My_Boat)
tmolitor-stud-tu Apr 30, 2024
f9f882e
fixup_workflow
tmolitor-stud-tu Apr 30, 2024
8c6e45f
Add filtering entitlement to macos alpha builds
tmolitor-stud-tu Apr 30, 2024
6a33414
Fix debug view appearance on macOS
tmolitor-stud-tu May 1, 2024
42bcdc0
Make keyboard auto-appear configurable
tmolitor-stud-tu May 1, 2024
5f6ee3c
Better error propagation in MLFiletransfer
tmolitor-stud-tu May 1, 2024
5238c48
Clean up Privacy Settings code
tmolitor-stud-tu May 1, 2024
f6a55e0
Fix detection of omemo keys in group-type mucs, fixes #1051
tmolitor-stud-tu May 2, 2024
cb5d6ce
Add workflows to only update translations
tmolitor-stud-tu May 1, 2024
0daadbe
Rework swift localizable strings extraction
tmolitor-stud-tu May 1, 2024
fad2b76
Make Toggle() translatable
tmolitor-stud-tu May 2, 2024
91e943a
Clean up "omemo not posible" code
tmolitor-stud-tu May 2, 2024
82a4b71
Change height to fit notification privacy picker items
tmolitor-stud-tu May 2, 2024
bb386e5
Show muc server in server details
tmolitor-stud-tu May 2, 2024
4e6df1b
Fix muc error display, fix muc server discovery, cleanup code
tmolitor-stud-tu May 2, 2024
b2b17e7
Fix localization update script
tmolitor-stud-tu May 2, 2024
230b17e
Fix timeout handling when creating mucs
tmolitor-stud-tu May 2, 2024
26ddd11
Don't assert when activating same audio session (pointer equality)
tmolitor-stud-tu May 2, 2024
d2b6d55
Make Picker() translatable, too
tmolitor-stud-tu May 2, 2024
02fb8b6
Bump marketing version to 6.3.1
tmolitor-stud-tu May 2, 2024
c0222aa
Update privacy settings submenu label
tmolitor-stud-tu May 2, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/beta.build-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,22 +75,22 @@ jobs:
chmod +x ./scripts/updateLocalization.sh
chmod +x ./scripts/xliff_extractor.py
./scripts/updateLocalization.sh BUILDSERVER
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: monal-catalyst
path: Monal/build/app/Monal.zip
if-no-files-found: error
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: monal-ios
path: Monal/build/ipa/Monal.ipa
if-no-files-found: error
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: monal-catalyst-dsym
path: Monal/build/macos_Monal.xcarchive/dSYMs
if-no-files-found: error
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: monal-ios-dsym
path: Monal/build/ios_Monal.xcarchive/dSYMs
Expand Down
33 changes: 19 additions & 14 deletions .github/workflows/develop-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,23 +64,28 @@ jobs:
run: xcrun notarytool submit ./Monal/build/app/Monal.alpha.zip --wait --team-id S8D843U34Y --key "/Users/ci/appstoreconnect/apiKey.p8" --key-id "$(cat /Users/ci/appstoreconnect/apiKeyId.txt)" --issuer "$(cat /Users/ci/appstoreconnect/apiIssuerId.txt)"
- name: Update monal homebrew alpha repo
run: scripts/updateAlphaHomebrew.sh
#- uses: actions/upload-artifact@v3
# with:
# name: monal-catalyst
# path: "Monal/build/app/Monal.alpha.tar"
# if-no-files-found: error
#- uses: actions/upload-artifact@v3
# with:
# name: monal-ios
# path: "Monal/build/ipa/Monal.alpha.ipa"
# if-no-files-found: error
#- uses: actions/upload-artifact@v3
# with:
- uses: actions/upload-artifact@v4
with:
name: monal-catalyst
path: "Monal/build/app/Monal.alpha.tar"
if-no-files-found: error
- uses: actions/upload-artifact@v4
with:
name: monal-ios
path: "Monal/build/ipa/Monal.alpha.ipa"
if-no-files-found: error
# - uses: actions/upload-artifact@v4
# with:
# name: monal-catalyst-dsym
# path: Monal/build/macos_Monal.xcarchive/dSYMs
# if-no-files-found: error
#- uses: actions/upload-artifact@v3
# with:
# - uses: actions/upload-artifact@v4
# with:
# name: monal-ios-dsym
# path: Monal/build/ios_Monal.xcarchive/dSYMs
# if-no-files-found: error
# - name: Update translations
# run: |
# chmod +x ./scripts/updateLocalization.sh
# chmod +x ./scripts/xliff_extractor.py
# ./scripts/updateLocalization.sh NOCOMMIT
34 changes: 17 additions & 17 deletions .github/workflows/stable.build-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,41 +76,41 @@ jobs:
- name: Extract version number and changelog from newest merge commit
id: releasenotes
run: |
buildNumber=$(git tag --sort="v:refname" |grep "Build_iOS" | tail -n1 | sed 's/Build_iOS_//g')
buildNumber=$(git tag --sort="v:refname" | grep "Build_iOS" | tail -n1 | sed 's/Build_iOS_//g')
echo "tag=Build_iOS_$buildNumber" >> "$GITHUB_OUTPUT"
echo "name=$(git log -n 1 --merges --pretty=format:%s)" >> "$GITHUB_OUTPUT"
echo "name=$(git log -n 1 --merges --pretty=format:%s | sed -E 's/^\s*([^\s]+)\s+\(([^\s]+)\)$/\1 (Build '$buildNumber', PR \2)/g')" >> "$GITHUB_OUTPUT"
echo "notes=$(git log -n 1 --merges --pretty=format:%b)" >> "$GITHUB_OUTPUT"
- name: Release
uses: softprops/action-gh-release@v2
with:
name: Release ${{ steps.releasenotes.outputs.name }}
tag_name: ${{ steps.releasenotes.outputs.tag }}
name: "Release ${{ steps.releasenotes.outputs.name }}"
tag_name: "${{ steps.releasenotes.outputs.tag }}"
target_commitish: stable
generate_release_notes: false
body: ${{ steps.releasenotes.outputs.notes }}
body: "${{ steps.releasenotes.outputs.notes }}"
files: |
./Monal/build/ipa/Monal.ipa
./Monal/build/app/Monal.zip
fail_on_unmatched_files: true
token: ${{ secrets.GITHUB_TOKEN }}
draft: false
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: monal-catalyst-pkg
path: Monal/build/app/Monal.pkg
if-no-files-found: error
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: monal-ios
path: Monal/build/ipa/Monal.ipa
if-no-files-found: error
- uses: actions/upload-artifact@v3
with:
name: monal-catalyst-dsym
path: Monal/build/macos_Monal.xcarchive/dSYMs
if-no-files-found: error
- uses: actions/upload-artifact@v3
with:
name: monal-ios-dsym
path: Monal/build/ios_Monal.xcarchive/dSYMs
if-no-files-found: error
# - uses: actions/upload-artifact@v4
# with:
# name: monal-catalyst-dsym
# path: Monal/build/macos_Monal.xcarchive/dSYMs
# if-no-files-found: error
# - uses: actions/upload-artifact@v4
# with:
# name: monal-ios-dsym
# path: Monal/build/ios_Monal.xcarchive/dSYMs
# if-no-files-found: error
33 changes: 33 additions & 0 deletions .github/workflows/update-translations.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# build a new beta release and push it to apple
name: update-translations

# Controls when the action will run.
on:
workflow_dispatch:

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
updateTranslations:
# The type of runner that the job will run on
runs-on: self-hosted
env:
APP_NAME: "Monal"
APP_DIR: "Monal.app"
BUILD_TYPE: "Beta"
EXPORT_OPTIONS_CATALYST_APPSTORE: "../scripts/exportOptions/Stable_Catalyst_ExportOptions.plist"
EXPORT_OPTIONS_CATALYST_APP_EXPORT: "../scripts/exportOptions/Beta_Catalyst_ExportOptions.plist"
EXPORT_OPTIONS_IOS: "../scripts/exportOptions/Beta_iOS_ExportOptions.plist"
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- uses: actions/checkout@v4
with:
clean: true
submodules: true
- name: Checkout submodules
run: git submodule update -f --init --remote
- name: Update translations
run: |
chmod +x ./scripts/updateLocalization.sh
chmod +x ./scripts/xliff_extractor.py
./scripts/updateLocalization.sh BUILDSERVER
2 changes: 2 additions & 0 deletions Monal/Alpha.Monal.macos.entitlements
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<dict>
<key>aps-environment</key>
<string>production</string>
<key>com.apple.developer.usernotifications.filtering</key>
<true/>
<key>com.apple.developer.usernotifications.communication</key>
<true/>
<key>com.apple.security.app-sandbox</key>
Expand Down
24 changes: 12 additions & 12 deletions Monal/Classes/AddContactMenu.swift
Original file line number Diff line number Diff line change
Expand Up @@ -136,24 +136,24 @@ struct AddContactMenu: View {
}
showLoadingOverlay(overlay, headline: NSLocalizedString("Adding...", comment: ""))
account.checkJidType(jid, withCompletion: { type, errorMsg in
if(type == "account") {
if type == "account" {
hideLoadingOverlay(overlay)
let contact = MLContact.createContact(fromJid: jid, andAccountNo: account.accountNo)
self.newContact = contact
MLXMPPManager.sharedInstance().add(contact, withPreauthToken:preauthToken)
//import omemo fingerprints as manually trusted, if requested
trustFingerprints(self.importScannedFingerprints ? self.scannedFingerprints : [:], for:jid, on:account)
successAlert(title: Text("Permission Requested"), message: Text("The new contact will be added to your contacts list when the person you've added has approved your request."))
} else if(type == "muc") {
} else if type == "muc" {
showLoadingOverlay(overlay, headline: NSLocalizedString("Adding Group/Channel...", comment: ""))
account.mucProcessor.addUIHandler({data in
let success : Bool = (data as! NSDictionary)["success"] as! Bool;
hideLoadingOverlay(overlay)
if(success) {
if success {
self.newContact = MLContact.createContact(fromJid: jid, andAccountNo: account.accountNo)
successAlert(title: Text("Success!"), message: Text(String.localizedStringWithFormat("Successfully joined group/channel %@!", jid)))
} else {
errorAlert(title: Text("Error entering group/channel!"))
errorAlert(title: Text("Error entering group/channel!"), message: Text((data as! NSDictionary)["errorMessage"] as! String))
}
}, forMuc: jid)
account.joinMuc(jid)
Expand All @@ -168,14 +168,14 @@ struct AddContactMenu: View {
let account = self.connectedAccounts[selectedAccount]
let splitJid = HelperTools.splitJid(account.connectionProperties.identity.jid)
Form {
if(connectedAccounts.isEmpty) {
if connectedAccounts.isEmpty {
Text("Please make sure at least one account has connected before trying to add a contact or channel.")
.foregroundColor(.secondary)
}
else
{
Section(header:Text("Contact and Group/Channel Jids are usually in the format: [email protected]")) {
if(connectedAccounts.count > 1) {
if connectedAccounts.count > 1 {
Picker("Use account", selection: $selectedAccount) {
ForEach(Array(self.connectedAccounts.enumerated()), id: \.element) { idx, account in
Text(account.connectionProperties.identity.jid).tag(idx)
Expand All @@ -196,15 +196,15 @@ struct AddContactMenu: View {
toAdd = toAdd.replacingOccurrences(of: " ", with: "")
}
}
if(scannedFingerprints != nil && scannedFingerprints!.count > 0) {
if scannedFingerprints != nil && scannedFingerprints!.count > 0 {
Section(header: Text("A contact was scanned through the QR code scanner")) {
Toggle(isOn: $importScannedFingerprints, label: {
Toggle(isOn: $importScannedFingerprints) {
Text("Import and trust OMEMO fingerprints from QR code")
})
}
}
}
Section {
if(scannedFingerprints != nil) {
if scannedFingerprints != nil {
Button(action: {
toAdd = ""
importScannedFingerprints = true
Expand All @@ -217,9 +217,9 @@ struct AddContactMenu: View {
Button(action: {
showAlert = toAddEmptyAlert || toAddInvalidAlert

if(!showAlert) {
if !showAlert {
let jidComponents = HelperTools.splitJid(toAdd)
if(jidComponents["host"] == nil || jidComponents["host"]!.isEmpty) {
if jidComponents["host"] == nil || jidComponents["host"]!.isEmpty {
errorAlert(title: Text("Error"), message: Text("Something went wrong while parsing the string..."))
showAlert = true
return
Expand Down
11 changes: 5 additions & 6 deletions Monal/Classes/ContactDetails.swift
Original file line number Diff line number Diff line change
Expand Up @@ -140,15 +140,14 @@ struct ContactDetails: View {
.addClearButton(isEditing: isEditingNickname, text: $contact.nickNameView)
}

Toggle("Pin Chat", isOn: Binding(get: {
Toggle(isOn: Binding(get: {
contact.isPinned
}, set: {
contact.obj.togglePinnedChat($0)
}))
// Button(contact.isPinned ? "Unpin Chat" : "Pin Chat") {
// contact.obj.togglePinnedChat(!contact.isPinned);
// }

})) {
Text("Pin Chat")
}

if(contact.obj.isGroup && contact.obj.mucType == "group") {
NavigationLink(destination: LazyClosureView(MemberList(mucContact:contact))) {
Text("Group Members")
Expand Down
57 changes: 31 additions & 26 deletions Monal/Classes/CreateGroupMenu.swift
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,14 @@ struct CreateGroupMenu: View {

var body: some View {
Form {
if(connectedAccounts.isEmpty) {
if connectedAccounts.isEmpty {
Text("Please make sure at least one account has connected before trying to create new group.")
.foregroundColor(.secondary)
}
else
{
Section() {
Picker("Use account", selection: $selectedAccount) {
Picker(selection: $selectedAccount, label: Text("Use account")) {
ForEach(Array(self.connectedAccounts.enumerated()), id: \.element) { idx, account in
Text(account.connectionProperties.identity.jid).tag(account as xmpp?)
}
Expand All @@ -70,41 +70,46 @@ struct CreateGroupMenu: View {
Text("Change Group Members")
})
Button(action: {
guard let generatedJid = self.selectedAccount!.mucProcessor.generateMucJid() else {
errorAlert(title: Text("Error creating group!"), message: Text("Your server does not provide a MUC component."))
return
}
showLoadingOverlay(overlay, headline: NSLocalizedString("Creating Group", comment: ""))
let roomJid = self.selectedAccount!.mucProcessor.createGroup(nil)
if(roomJid == nil) {
let groupContact = MLContact.createContact(fromJid: roomJid!, andAccountNo: self.selectedAccount!.accountNo)
guard let roomJid = self.selectedAccount!.mucProcessor.createGroup(generatedJid) else {
//room already existing in our local bookmarks --> just open it
//this should never happen since we randomly generated a jid above
hideLoadingOverlay(overlay)
let groupContact = MLContact.createContact(fromJid: generatedJid, andAccountNo: self.selectedAccount!.accountNo)
self.delegate.dismissWithoutAnimation()
if let activeChats = self.appDelegate.activeChats {
activeChats.presentChat(with:groupContact)
}
} else {
self.selectedAccount!.mucProcessor.addUIHandler({data in
let success : Bool = (data as! NSDictionary)["success"] as! Bool;
if(success) {
self.selectedAccount!.mucProcessor.changeName(ofMuc: roomJid!, to: self.groupName)
for user in self.selectedContacts {
self.selectedAccount!.mucProcessor.setAffiliation("member", ofUser: user.contactJid, inMuc: roomJid!)
self.selectedAccount!.mucProcessor.inviteUser(user.contactJid, inMuc: roomJid!)
}
let groupContact = MLContact.createContact(fromJid: roomJid!, andAccountNo: self.selectedAccount!.accountNo)
hideLoadingOverlay(overlay)
self.delegate.dismissWithoutAnimation()
if let activeChats = self.appDelegate.activeChats {
activeChats.presentChat(with:groupContact)
}
} else {
hideLoadingOverlay(overlay)
errorAlert(title: Text("Error creating group!"))
}
}, forMuc: roomJid!)
return
}
self.selectedAccount!.mucProcessor.addUIHandler({data in
let success : Bool = (data as! NSDictionary)["success"] as! Bool;
if success {
self.selectedAccount!.mucProcessor.changeName(ofMuc: roomJid, to: self.groupName)
for user in self.selectedContacts {
self.selectedAccount!.mucProcessor.setAffiliation("member", ofUser: user.contactJid, inMuc: roomJid)
self.selectedAccount!.mucProcessor.inviteUser(user.contactJid, inMuc: roomJid)
}
let groupContact = MLContact.createContact(fromJid: roomJid, andAccountNo: self.selectedAccount!.accountNo)
hideLoadingOverlay(overlay)
self.delegate.dismissWithoutAnimation()
if let activeChats = self.appDelegate.activeChats {
activeChats.presentChat(with:groupContact)
}
} else {
hideLoadingOverlay(overlay)
errorAlert(title: Text("Error creating group!"), message: Text((data as! NSDictionary)["errorMessage"] as! String))
}
}, forMuc: roomJid)
}, label: {
Text("Create new group")
})
}
if(self.selectedContacts.count > 0) {
if self.selectedContacts.count > 0 {
Section(header: Text("Selected Group Members")) {
ForEach(self.selectedContacts, id: \.obj.contactJid) { contact in
ContactEntry(contact: contact)
Expand Down
Loading