Skip to content

Commit

Permalink
Merge pull request #25 from nimblehq/release/0.1.0
Browse files Browse the repository at this point in the history
Release 0.1.0
  • Loading branch information
Thieurom authored Dec 5, 2022
2 parents 342d9d5 + 812821e commit af7fb30
Show file tree
Hide file tree
Showing 80 changed files with 20,068 additions and 31 deletions.
2 changes: 2 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# @Thieurom is the Team Lead.
* @minhnimble @Thieurom @nkhanh44
52 changes: 52 additions & 0 deletions .github/workflows/automatic_pull_request_review.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Automatic pull request review

on:
pull_request:
types: [opened, reopened, edited, synchronize]

jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Run SwiftLint
uses: norio-nomura/[email protected]
with:
args: --strict

review_pull_request:
name: Pull request review
runs-on: macOS-12
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v3
with:
fetch-depth: 0

- uses: actions/cache@v3
id: bunlderCache
with:
path: vendor/bundle
key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-gems-
- name: Setup
run: make setup

- name: Build and Test
run: bundle exec fastlane buildAndTest
env:
CI: true

- name: Clean up previous code coverage report
run: bundle exec fastlane cleanUpOutput
47 changes: 47 additions & 0 deletions .github/workflows/deploy_Firebase.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Deploy Build To Firebase

on:
push:
branches: [ develop ]
workflow_dispatch:

jobs:
build:
name: Build
runs-on: macos-12
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Install SSH key
uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

- name: Install Firebase-Tools
run: |
yarn add firebase-tools
echo "$(yarn global bin)" >> $GITHUB_PATH
- name: Setup
run: make setup

- name: Build and Test
run: bundle exec fastlane buildAndTest

- name: Match Ad-hoc
run: bundle exec fastlane syncAdHocStagingCodeSigning
env:
KEYCHAIN_PASSWORD: ${{ secrets.KEYCHAIN_PASSWORD }}
MATCH_PASSWORD: ${{ secrets.MATCH_PASS }}

- name: Build App and Distribute to Firebase
run: bundle exec fastlane buildStagingAndUploadToFirebase --verbose
env:
FIREBASE_TOKEN: ${{ secrets.FIREBASE_CLI_TOKEN }}
42 changes: 42 additions & 0 deletions .github/workflows/deploy_Release_Firebase.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Deploy Release Build To Firebase

on:
push:
branches: [ release/** ]
workflow_dispatch:

jobs:
build:
name: Build
runs-on: macos-12
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Install SSH key
uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

- name: Setup
run: make setup

- name: Build and Test
run: bundle exec fastlane buildAndTest

- name: Match Ad-hoc
run: bundle exec fastlane syncAdHocProductionCodeSigning
env:
KEYCHAIN_PASSWORD: ${{ secrets.KEYCHAIN_PASSWORD }}
MATCH_PASSWORD: ${{ secrets.MATCH_PASS }}

- name: Build Production App and Distribute to Firebase
run: bundle exec fastlane buildProductionAndUploadToFirebase
env:
FIREBASE_TOKEN: ${{ secrets.FIREBASE_CLI_TOKEN }}
47 changes: 16 additions & 31 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,36 +1,21 @@
*.gem
*.rbc
/.config
/.idea
/coverage/
/InstalledFiles
/node_modules
/pkg/
/spec/reports/
/spec/examples.txt
/test/tmp/
/test/version_tmp/
/tmp/
# Mac
.DS_Store

# Used by dotenv library to load environment variables.
# .env
# Xcode
xcuserdata/

## Documentation cache and generated files:
/.yardoc/
/_yardoc/
/doc/
/rdoc/
# Derived Data folder
DerivedData/
Build/

## Environment normalization:
/.bundle/
/vendor/bundle
/lib/bundler/man/
# fastlane
fastlane/report.xml
fastlane/Preview.html
fastlane/screenshots/**/*.png
fastlane/screenshots/screenshots.html
fastlane/test_output
fastlane/FastlaneRunner

# for a library or gem, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
# Gemfile.lock
# .ruby-version
# .ruby-gemset
# Bundler

# unless supporting rvm < 1.11.0 or doing something fancy, ignore this:
.rvmrc
vendor/bundle
17 changes: 17 additions & 0 deletions .swiftformat
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# file options
--exclude Generated, **/*.generated.swift

# rules
--disable fileHeader
--disable initCoderUnavailable
--disable trailingCommas
--disable wrapEnumCases
--disable wrapMultilineStatementBraces
--disable wrapSwitchCases
--disable blankLinesAtStartOfScope
--stripunusedargs closure-only
--extensionacl on-declarations
--wraparguments before-first
--wrapparameters before-first
--wrapcollections before-first
--maxwidth 120
117 changes: 117 additions & 0 deletions .swiftlint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
included:
- CryptoPrices
- CryptoPricesTests
- CryptoPricesUITests

excluded:
- Derived
- DerivedData

opt_in_rules:
- anyobject_protocol
- array_init
- attributes
- closure_body_length
- closure_end_indentation
- closure_spacing
- collection_alignment
- contains_over_first_not_nil
- convenience_type
- discouraged_object_literal
- discouraged_optional_boolean
- empty_count
- empty_string
- empty_xctest_method
- explicit_init
- fallthrough
- fatal_error_message
- file_name
- file_types_order
- first_where
- force_unwrapping
- identical_operands
- implicit_return
- joined_default_parameter
- last_where
- legacy_multiple
- legacy_random
- let_var_whitespace
- literal_expression_end_indentation
- lower_acl_than_parent
- modifier_order
- multiline_arguments
- multiline_function_chains
- multiline_literal_brackets
- multiline_parameters
- nimble_operator
- number_separator
- operator_usage_whitespace
- overridden_super_call
- override_in_extension
- private_action
- private_outlet
- prohibited_super_call
- quick_discouraged_focused_test
- quick_discouraged_pending_test
- reduce_into
- redundant_nil_coalescing
- single_test_class
- sorted_first_last
- static_operator
- strong_iboutlet
- toggle_bool
- type_contents_order
- unneeded_parentheses_in_closure_argument
- unowned_variable_capture
- untyped_error_in_catch
- vertical_parameter_alignment_on_call
- xct_specific_matcher
- yoda_condition
disabled_rules:
- todo

attributes:
always_on_same_line:
- '@objc'
identifier_name:
excluded:
- id
line_length:
ignores_function_declarations: true
ignores_comments: true
modifier_order:
preferred_modifier_order:
- acl
- setterACL
- override
- dynamic
- mutators
- lazy
- final
- required
- convenience
- typeMethods
- owned
nesting:
type_level:
warning: 2
number_separator:
minimum_fraction_length: 10
trailing_whitespace:
ignores_empty_lines: true
implicit_return:
included:
- closure
- getter

custom_rules:
multiline_collection_one_per_line:
name: 'Multiline Collection One Per Line'
message: 'Collection should be either on the same line, or one per line.'
regex: '\[\n([^\[\(])*(,([^\n\r])*[\w]+)([^\[])*\n(\s)*]'
severity: warning
multiline_arguments_one_per_line:
name: 'Multiline Arguments One Per Line'
message: 'Arguments should be either on the same line, or one per line.'
regex: '[^\n\r]\(\n([^\(<])*([^\n\r],([^\n\r])*[\w]+)([^\)])*\n(\s)*\)'
severity: warning
Loading

0 comments on commit af7fb30

Please sign in to comment.