Skip to content

one-and-only/swap-ios-wallet

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 

Repository files navigation

Swap iOS Wallet

iOS Wallet for Swap, made by Revvz (me, but on Discord).

WARNING: Since I now have an M1 Mac, compiling on an Intel Mac may no longer work. It should, but I make no guarantees

Setting up React Native Development Environment

  1. Install Homebrew
  2. Open a terminal and run brew install node watchman npm
  3. Install CocoaPods by running sudo gem install cocoapods

Setting Up Code Workspace

NOTE: Before continuing, make sure you've done everything in the previous section

  1. Go to the Mac App Store and install XCode
  2. Install the XCode Command Line Developer Tools. After installing XCode, open up a Terminal Emulator and run xcode-select --install
  3. Clone this repository: git clone https://github.com/one-and-only/swap-ios-wallet.git
  4. Open a Terminal Emulator, and cd into the folder you stored this repository and cd once more into SwapiOSWallet.
  5. using npm, run npm install. This installs all dependencies needed by the core project
  6. Link everything required for the app using npx react-native link. This copies over certain resources required for the app to compile/run.
  7. The above command should have installed CocoaPods. With this installed, run cd ios && pod install. This will install all required Pod dependencies needed to run development versions of the iOS wallet.
  8. You're Done! 🎉

Setting Up Analytics Collection

NOTE: Analytics collection is being handled by Firebase. Before continuing, make sure you've done everything in the previous section You will need a google-services.json file for analytics on Android and a GoogleService-Info.plist.

  1. Consult Download Firebase config file or object
  2. For iOS/iPadOS App, scroll to Get config file for your iOS app and follow the instructions
    1. NOTE: GoogleService-Info.plist should be placed in <repo-dir>/ios/ and added to XCode, if it isn't done automatically.
  3. For Android, scroll to Get config file for your Android app and follow the instructions
    1. NOTE: google-services.json should be placed in <repo-dir>/android/app/ and added to Android Studio, if it isn't done automatically.

Running Development Versions of Swap iOS Wallet

NOTE: Before continuing, make sure you've done everything in the previous section

  1. Open the SwapiOSWallet.xcworkspace file using XCode. It is stored in SwapiOSWallet/ios, relative to the repository's residing folder.
  2. Choose the scheme (AKA the phone and iOS version you want to simulate) from the top left, and hit the Run button (looks like a play button), which is located to the left of the scheme selection.
  3. Your app should build, and then subsequently launch! 🎉

NOTE: You will be unable to build a valid signed Release build of the app, since the keystore (Android) or the signing configuration (iOS/iPadOS) is not provided in this repository. The repository author is the only person allowed to build and publish app updates.

Running on an M1 Mac

  1. Do everything in Setting Up Code Workspace up to step 5. IT IS IMPORTANT YOU DON'T DO ANYTHING AFTER THAT STEP.
  2. In a terminal, run sudo gem install ffi
  3. Since CocoaPods only works on Intel Macs, you will either need to run the entire terminal with Rosetta 2 and then run cd ios && pod install, or install pods using cd ios && arch -x86_64 pod install
  4. Now you may proceed to Running Development Versions of Swap iOS Wallet

NOTE About My Unverified Commits

A lot of my commits are now showing up as Unverified. This is because my previous GPG key got wiped from my machine and I didn't have a backup. The key has NOT been compromised as far as I am aware, but I don't have access to it anymore. Thus, I removed it. Any commits with the GPG Key ID of EB2D38C332D61F26 should be considered Verified. Thank you for your understanding.