Commit Graph

26 Commits

Author SHA1 Message Date
Ehren Kret
d4e17730f3 remove import SignalMessaging statements 2024-03-12 03:35:34 -05:00
Max Radermacher
0f5cff5dd4
Clean up PaymentsFormatTest 2024-01-09 11:04:06 -06:00
Max Radermacher
d52082abbe
Prefer IdentityKey over typeless Data objects 2023-11-07 11:37:02 -06:00
Max Radermacher
600eef4bec
Replace Curve25519Kit with LibSignal 2023-10-31 14:18:22 -05:00
Igor Solomennikov
20c55e7dec
Add necessary imports to Swift files.
Necessary for converting ChatListVC to Swift.
2023-06-05 16:04:48 -07:00
Max Radermacher
22ef2d8e55
Swiftify AppSetup 2023-04-12 17:54:48 -07:00
Evan Hahn
ec78cc3a0a
Hide Apple Pay UI when the server disallows your region
_I recommend reviewing this with whitespace changes disabled._

The server's `global.donations.apayDisabledRegions` is a list of regions
(phone number prefixes) where Apple Pay is disallowed. This respects
that.
2022-11-10 16:19:47 -06:00
Evan Hahn
370ff654e7
Change license to AGPL
Change license to AGPL

This commit:

- Updates the `LICENSE` file

- Start every file with something like:

      // Copyright YEAR_FIRST_PUBLISHED Signal Messenger, LLC
      // SPDX-License-Identifier: AGPL-3.0-only

---

First, I removed existing license headers with this Ruby 3.1.2 script:

    require 'set'

    EXTENSIONS_TO_CHECK = Set['.h', '.hpp', '.cpp', '.m', '.mm', '.pch', '.swift']

    same = 0
    different = 0

    all_files = `git ls-files`.lines.map { |line| line.strip }
    all_files.each do |relative_path|
      if relative_path == 'Pods'
        next
      end

      unless EXTENSIONS_TO_CHECK.include? File.extname(relative_path)
        next
      end

      path = File.expand_path(relative_path)

      contents = File.read(path)
      new_contents = contents.sub(/\/\/\n\/\/  Copyright .*\n\/\/\n\n/, '')

      if contents == new_contents
        same += 1
      else
        different += 1
      end

      File.write(path, new_contents)
    end

    puts "updated #{different} file(s), left #{same} untouched"

I'm sure this script could be improved, but it worked well enough.

Then, I created `Scripts/lint/lint-license-headers` and ran it to auto-
fix a lot of files. This changed the mode of some files, but I think
that's actually desirable. For example,
`SignalServiceKit/src/Util/AppContext.m` previously had a mode of
`0755/-rwxr-xr-x`, and it's now `0644/-rw-r--r--`.

Then I fixed some stragglers and updated the precommit script.

See [a similar change in the Desktop app][0].

[0]: 8bfaf598af
2022-10-13 08:25:37 -05:00
Evan Hahn
a066511a62 Remove useless test setup/teardown
We had a lot of functions like this, which are useless:

    override func setUp() {
        super.setUp()
    }

This removes them.
2022-10-04 14:06:34 -07:00
Evan Hahn
0da97a3e54 Prefer "blocklist"
This replaces the word "blacklist" with "blocklist" across the codebase.

Luckily, there was only one method (and its test) that needed renaming.
2022-04-29 18:34:19 -05:00
Matthew Chen
2384141e94 Fix broken test. 2021-11-18 22:51:37 -03:00
Matthew Chen
664d9cd671 Payments region remote config. 2021-11-17 16:34:59 -08:00
Matthew Chen
bcc693e8e7 Move MobileCoin SDK to SignalUI. 2021-11-02 14:26:04 -03:00
Michelle Linington
34062baddd Drop PromiseKit from test import 2021-09-03 14:55:40 -07:00
Nora Trapp
2814ab7629 Convert to new Promise library 2021-09-03 11:41:34 -07:00
Matthew Chen
a3bd0338d5 Refine payments formatting. 2021-09-01 16:30:48 -03:00
Matthew Chen
7abfeeb2ae Payments: Clean up. 2021-04-06 13:57:11 -03:00
Matthew Chen
f130126b5b Update MC SDK; adopt new payment entropy derivation scheme; update auth credential handling. 2021-04-06 13:57:10 -03:00
Matthew Chen
bac99faa83 Configure for signal mainnet; tweak payments public address signature. 2021-04-06 13:57:10 -03:00
Matthew Chen
beee556eac Fix rebase breakage. 2021-04-06 13:57:10 -03:00
Matthew Chen
532976bd76 Fix rebase breakage. 2021-04-06 13:57:10 -03:00
Matthew Chen
d95a65da02 Payments: integrate with SDK support for entropy & passphrases. 2021-04-06 13:57:09 -03:00
Matthew Chen
4c424d7510 Fix broken tests. 2021-04-06 13:57:08 -03:00
Matthew Chen
ea6f8a7f86 Clean up formatting of MOB values for display. 2021-04-06 13:57:08 -03:00
Matthew Chen
d77ae7d012 Fix broken tests, bugs. 2021-04-06 13:57:08 -03:00
Matthew Chen
afd2aeef5c Payments UI. 2021-04-06 13:57:07 -03:00