mirror of
https://github.com/tooot-app/app
synced 2024-12-30 11:22:23 +01:00
Update branching
This commit is contained in:
parent
b21f1b5a0e
commit
a23f98842f
@ -1,4 +1,4 @@
|
||||
export TOOOT_ENVIRONMENT=""
|
||||
export ENVIRONMENT="development"
|
||||
|
||||
export SENTRY_ORGANIZATION=""
|
||||
export SENTRY_PROJECT=""
|
||||
|
@ -1,8 +1,5 @@
|
||||
name: Build development
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- development
|
||||
on: push
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: macos-latest
|
||||
@ -27,13 +24,13 @@ jobs:
|
||||
run: bundle install
|
||||
- name: -- Step 6 -- Run fastlane
|
||||
env:
|
||||
TOOOT_ENVIRONMENT: development
|
||||
ENVIRONMENT: ${{ secrets.ENVIRONMENT }}
|
||||
LC_ALL: en_US.UTF-8
|
||||
LANG: en_US.UTF-8
|
||||
SENTRY_ORGANIZATION: ${{ secrets.SENTRY_ORGANIZATION }}
|
||||
SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }}
|
||||
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
|
||||
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
|
||||
LC_ALL: en_US.UTF-8
|
||||
LANG: en_US.UTF-8
|
||||
FASTLANE_USER: ${{ secrets.FASTLANE_USER }}
|
||||
MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }}
|
||||
MATCH_GIT_URL: ${{ secrets.MATCH_GIT_URL }}
|
33
.github/workflows/production.yml
vendored
33
.github/workflows/production.yml
vendored
@ -1,33 +0,0 @@
|
||||
name: Publish production
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
jobs:
|
||||
publish:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: -- Step 1 -- Checkout code
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
submodules: true
|
||||
- name: -- Step 2 -- Setup node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 14.x
|
||||
- name: -- Step 3 -- Use Expo action
|
||||
uses: expo/expo-github-action@v5
|
||||
with:
|
||||
expo-version: 4.x
|
||||
expo-username: ${{ secrets.EXPO_USERNAME }}
|
||||
expo-token: ${{ secrets.EXPO_TOKEN }}
|
||||
- name: -- Step 4 -- Install dependencies
|
||||
run: yarn install
|
||||
- name: -- Step 5 -- Publish
|
||||
env:
|
||||
SENTRY_ORGANIZATION: ${{ secrets.SENTRY_ORGANIZATION }}
|
||||
SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }}
|
||||
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
|
||||
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
|
||||
SENTRY_DEPLOY_ENV: production
|
||||
run: expo publish --release-channel=${GITHUB_REF#refs/heads/}
|
53
.github/workflows/staging.yml
vendored
53
.github/workflows/staging.yml
vendored
@ -1,53 +0,0 @@
|
||||
name: Build staging
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- staging
|
||||
jobs:
|
||||
build:
|
||||
runs-on: macos-latest
|
||||
steps:
|
||||
- name: -- Step 1 -- Checkout code
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
submodules: true
|
||||
- name: -- Step 2 -- Setup node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 14.x
|
||||
- name: -- Step 3 -- Use Expo action
|
||||
uses: expo/expo-github-action@v5
|
||||
with:
|
||||
expo-version: 4.x
|
||||
expo-username: ${{ secrets.EXPO_USERNAME }}
|
||||
expo-token: ${{ secrets.EXPO_TOKEN }}
|
||||
- name: -- Step 4 -- Install node dependencies
|
||||
run: yarn install
|
||||
- name: -- Step 5 -- Install native dependencies
|
||||
run: npx pod-install
|
||||
- name: -- Step 6 -- Install ruby dependencies
|
||||
run: bundle install
|
||||
- name: -- Step 7 -- Run fastlane
|
||||
env:
|
||||
TOOOT_ENVIRONMENT: staging
|
||||
SENTRY_ORGANIZATION: ${{ secrets.SENTRY_ORGANIZATION }}
|
||||
SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }}
|
||||
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
|
||||
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
|
||||
LC_ALL: en_US.UTF-8
|
||||
LANG: en_US.UTF-8
|
||||
FASTLANE_USER: ${{ secrets.FASTLANE_USER }}
|
||||
MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }}
|
||||
MATCH_GIT_URL: ${{ secrets.MATCH_GIT_URL }}
|
||||
MATCH_GIT_BASIC_AUTHORIZATION: ${{ secrets.MATCH_GIT_BASIC_AUTHORIZATION }}
|
||||
APP_STORE_CONNECT_API_KEY_KEY_ID: ${{ secrets.APP_STORE_CONNECT_API_KEY_KEY_ID }}
|
||||
APP_STORE_CONNECT_API_KEY_ISSUER_ID: ${{ secrets.APP_STORE_CONNECT_API_KEY_ISSUER_ID }}
|
||||
APP_STORE_CONNECT_API_KEY_KEY: ${{ secrets.APP_STORE_CONNECT_API_KEY_KEY }}
|
||||
ANDROID_KEYSTORE: ${{ secrets.ANDROID_KEYSTORE }}
|
||||
ANDROID_KEYSTORE_PASSWORD: ${{ secrets.ANDROID_KEYSTORE_PASSWORD }}
|
||||
ANDROID_KEYSTORE_ALIAS: ${{ secrets.ANDROID_KEYSTORE_ALIAS }}
|
||||
ANDROID_KEYSTORE_KEY_PASSWORD: ${{ secrets.ANDROID_KEYSTORE_KEY_PASSWORD }}
|
||||
SUPPLY_JSON_KEY_DATA: ${{ secrets.SUPPLY_JSON_KEY_DATA }}
|
||||
GH_PAT_GET_RELEASE: ${{ secrets.GH_PAT_GET_RELEASE }}
|
||||
FL_GITHUB_RELEASE_API_BEARER: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: yarn app:build
|
24
Gemfile.lock
24
Gemfile.lock
@ -7,16 +7,16 @@ GEM
|
||||
artifactory (3.0.15)
|
||||
atomos (0.1.3)
|
||||
aws-eventstream (1.1.1)
|
||||
aws-partitions (1.431.1)
|
||||
aws-sdk-core (3.112.1)
|
||||
aws-partitions (1.432.0)
|
||||
aws-sdk-core (3.113.0)
|
||||
aws-eventstream (~> 1, >= 1.0.2)
|
||||
aws-partitions (~> 1, >= 1.239.0)
|
||||
aws-sigv4 (~> 1.1)
|
||||
jmespath (~> 1.0)
|
||||
aws-sdk-kms (1.42.0)
|
||||
aws-sdk-kms (1.43.0)
|
||||
aws-sdk-core (~> 3, >= 3.112.0)
|
||||
aws-sigv4 (~> 1.1)
|
||||
aws-sdk-s3 (1.89.0)
|
||||
aws-sdk-s3 (1.91.0)
|
||||
aws-sdk-core (~> 3, >= 3.112.0)
|
||||
aws-sdk-kms (~> 1)
|
||||
aws-sigv4 (~> 1.1)
|
||||
@ -48,7 +48,7 @@ GEM
|
||||
faraday_middleware (1.0.0)
|
||||
faraday (~> 1.0)
|
||||
fastimage (2.2.3)
|
||||
fastlane (2.176.0)
|
||||
fastlane (2.178.0)
|
||||
CFPropertyList (>= 2.3, < 4.0.0)
|
||||
addressable (>= 2.3, < 3.0.0)
|
||||
artifactory (~> 3.0)
|
||||
@ -98,7 +98,7 @@ GEM
|
||||
representable (~> 3.0)
|
||||
retriable (>= 2.0, < 4.0)
|
||||
signet (~> 0.12)
|
||||
google-apis-core (0.2.1)
|
||||
google-apis-core (0.3.0)
|
||||
addressable (~> 2.5, >= 2.5.1)
|
||||
googleauth (~> 0.14)
|
||||
httpclient (>= 2.8.1, < 3.0)
|
||||
@ -108,17 +108,17 @@ GEM
|
||||
rexml
|
||||
signet (~> 0.14)
|
||||
webrick
|
||||
google-apis-iamcredentials_v1 (0.1.0)
|
||||
google-apis-iamcredentials_v1 (0.2.0)
|
||||
google-apis-core (~> 0.1)
|
||||
google-apis-storage_v1 (0.2.0)
|
||||
google-apis-storage_v1 (0.3.0)
|
||||
google-apis-core (~> 0.1)
|
||||
google-cloud-core (1.5.0)
|
||||
google-cloud-core (1.6.0)
|
||||
google-cloud-env (~> 1.0)
|
||||
google-cloud-errors (~> 1.0)
|
||||
google-cloud-env (1.4.0)
|
||||
google-cloud-env (1.5.0)
|
||||
faraday (>= 0.17.3, < 2.0)
|
||||
google-cloud-errors (1.0.1)
|
||||
google-cloud-storage (1.30.0)
|
||||
google-cloud-errors (1.1.0)
|
||||
google-cloud-storage (1.31.0)
|
||||
addressable (~> 2.5)
|
||||
digest-crc (~> 0.4)
|
||||
google-apis-iamcredentials_v1 (~> 0.1)
|
||||
|
@ -0,0 +1,3 @@
|
||||
# [tooot](https://tooot.app/) app for Mastodon
|
||||
|
||||
[![GPL-3.0](https://img.shields.io/github/license/tooot-app/push?style=flat-square)](LICENSE) ![GitHub Workflow Status](https://img.shields.io/github/workflow/status/tooot-app/app/build?style=flat-square) ![GitHub issues](https://img.shields.io/github/issues/tooot-app/app?style=flat-square) ![GitHub package.json version](https://img.shields.io/github/package-json/v/tooot-app/app?style=flat-square) ![Code Climate maintainability](https://img.shields.io/codeclimate/maintainability/tooot-app/app?style=flat-square)
|
@ -13,7 +13,6 @@ export default (): ExpoConfig => ({
|
||||
privacy: 'hidden',
|
||||
assetBundlePatterns: ['assets/*'],
|
||||
extra: {
|
||||
toootEnvironment: process.env.TOOOT_ENVIRONMENT,
|
||||
sentryDSN: process.env.SENTRY_DSN
|
||||
},
|
||||
hooks: {
|
||||
@ -25,7 +24,7 @@ export default (): ExpoConfig => ({
|
||||
project: process.env.SENTRY_PROJECT,
|
||||
authToken: process.env.SENTRY_AUTH_TOKEN,
|
||||
setCommits: process.env.GITHUB_SHA || undefined,
|
||||
deployEnv: process.env.TOOOT_ENVIRONMENT
|
||||
deployEnv: process.env.ENVIRONMENT
|
||||
}
|
||||
}
|
||||
]
|
||||
|
@ -1,12 +1,12 @@
|
||||
fastlane_version "2.173.0"
|
||||
fastlane_version "2.178.0"
|
||||
skip_docs
|
||||
|
||||
ensure_env_vars(
|
||||
env_vars: ["TOOOT_ENVIRONMENT", "SENTRY_ORGANIZATION", "SENTRY_PROJECT", "SENTRY_AUTH_TOKEN"]
|
||||
env_vars: ["ENVIRONMENT", "SENTRY_ORGANIZATION", "SENTRY_PROJECT", "SENTRY_AUTH_TOKEN"]
|
||||
)
|
||||
|
||||
VERSIONS = read_json( json_path: "./package.json" )[:versions]
|
||||
ENVIRONMENT = ENV["TOOOT_ENVIRONMENT"]
|
||||
ENVIRONMENT = ENV["ENVIRONMENT"]
|
||||
VERSION = "#{VERSIONS[:major]}.#{VERSIONS[:minor]}"
|
||||
RELEASE_CHANNEL = "#{VERSIONS[:major]}-#{VERSIONS[:minor]}-#{ENVIRONMENT}"
|
||||
BUILD_NUMBER = ENV["GITHUB_RUN_NUMBER"]
|
||||
@ -14,9 +14,9 @@ GITHUB_REPO = "tooot-app/app"
|
||||
case ENVIRONMENT
|
||||
when "development"
|
||||
GITHUB_RELEASE= ""
|
||||
when "staging"
|
||||
when "candidate"
|
||||
GITHUB_RELEASE = "v#{VERSION}-#{VERSIONS[:patch]}"
|
||||
when "production"
|
||||
when "release"
|
||||
GITHUB_RELEASE = "v#{VERSION}"
|
||||
end
|
||||
|
||||
@ -34,7 +34,7 @@ private_lane :prepare_appstore_ios do
|
||||
"NSAllowsArbitraryLoads" => false
|
||||
}
|
||||
)
|
||||
increment_build_number( xcodeproj: XCODEPROJ, build_number: BUILD_NUMBER )
|
||||
increment_build_number( xcodeproj: XCODEPROJ, build_number: BUILD_NUMBER, skip_info_plist: true )
|
||||
app_store_connect_api_key
|
||||
end
|
||||
|
||||
@ -44,6 +44,11 @@ private_lane :update_expo_ios do
|
||||
set_info_plist_value( path: EXPO_PLIST, key: "EXUpdatesReleaseChannel", value: RELEASE_CHANNEL )
|
||||
end
|
||||
|
||||
desc 'IOS: Install pods'
|
||||
private_lane :install_pods_ios do
|
||||
cocoapods(podfile: "./ios/", deployment: true)
|
||||
end
|
||||
|
||||
desc "ANDROID: Prepare play store"
|
||||
private_lane :prepare_playstore_android do
|
||||
android_set_version_name( version_name: VERSION, gradle_file: "./android/app/build.gradle" )
|
||||
@ -81,17 +86,19 @@ private_lane :build_ios do
|
||||
build_ios_app( export_method: "development", output_directory: BUILD_DIRECTORY )
|
||||
install_on_device( skip_wifi: true )
|
||||
end
|
||||
when "staging"
|
||||
when "candidate"
|
||||
install_pods_ios
|
||||
prepare_appstore_ios
|
||||
match( type: "appstore", readonly: true )
|
||||
build_ios_app( export_method: "app-store", include_symbols: true, include_bitcode: true )
|
||||
upload_to_testflight(
|
||||
demo_account_required: true,
|
||||
distribute_external: true,
|
||||
groups: "内测用户",
|
||||
groups: "测试用户",
|
||||
changelog: "Ready for testing"
|
||||
)
|
||||
when "production"
|
||||
when "release"
|
||||
install_pods_ios
|
||||
prepare_appstore_ios
|
||||
match( type: "appstore", readonly: true, include_bitcode: true )
|
||||
build_ios_app( export_method: "app-store" )
|
||||
@ -114,7 +121,7 @@ private_lane :build_android do
|
||||
command: "install #{lane_context[SharedValues::GRADLE_APK_OUTPUT_PATH]}"
|
||||
)
|
||||
end
|
||||
when "staging"
|
||||
when "candidate"
|
||||
prepare_playstore_android
|
||||
build_android_app(
|
||||
task: 'clean bundle',
|
||||
@ -138,7 +145,7 @@ private_lane :build_android do
|
||||
skip_upload_images: true,
|
||||
skip_upload_screenshots: true
|
||||
)
|
||||
when "production"
|
||||
when "release"
|
||||
end
|
||||
end
|
||||
|
||||
@ -151,9 +158,9 @@ lane :build do
|
||||
build_ios
|
||||
build_android
|
||||
case ENVIRONMENT
|
||||
when "staging"
|
||||
when "candidate"
|
||||
github_release(prerelease: true)
|
||||
when "production"
|
||||
when "release"
|
||||
github_release(prerelease: false)
|
||||
end
|
||||
end
|
||||
|
@ -83,7 +83,7 @@ const renderNode = ({
|
||||
<Text
|
||||
key={index}
|
||||
style={{
|
||||
color: accountIndex !== -1 ? theme.blue : undefined,
|
||||
color: accountIndex !== -1 ? theme.blue : theme.primary,
|
||||
fontSize: adaptedFontsize,
|
||||
lineHeight: adaptedLineheight
|
||||
}}
|
||||
|
@ -125,7 +125,7 @@ const TimelineDefault: React.FC<Props> = ({
|
||||
{!disableDetails && actualStatus.card && (
|
||||
<TimelineCard card={actualStatus.card} />
|
||||
)}
|
||||
<TimelineFullConversation status={actualStatus} />
|
||||
<TimelineFullConversation queryKey={queryKey} status={actualStatus} />
|
||||
</View>
|
||||
|
||||
{queryKey && !disableDetails && (
|
||||
|
@ -121,7 +121,10 @@ const TimelineNotifications: React.FC<Props> = ({
|
||||
{notification.status.card && (
|
||||
<TimelineCard card={notification.status.card} />
|
||||
)}
|
||||
<TimelineFullConversation status={notification.status} />
|
||||
<TimelineFullConversation
|
||||
queryKey={queryKey}
|
||||
status={notification.status}
|
||||
/>
|
||||
</View>
|
||||
) : null}
|
||||
</View>
|
||||
|
@ -1,3 +1,4 @@
|
||||
import { QueryKeyTimeline } from '@utils/queryHooks/timeline'
|
||||
import { StyleConstants } from '@utils/styles/constants'
|
||||
import { useTheme } from '@utils/styles/ThemeManager'
|
||||
import React from 'react'
|
||||
@ -5,15 +6,18 @@ import { useTranslation } from 'react-i18next'
|
||||
import { Text } from 'react-native'
|
||||
|
||||
export interface Props {
|
||||
queryKey?: QueryKeyTimeline
|
||||
status: Mastodon.Status
|
||||
}
|
||||
|
||||
const TimelineFullConversation = React.memo(
|
||||
({ status }: Props) => {
|
||||
({ queryKey, status }: Props) => {
|
||||
const { t } = useTranslation('componentTimeline')
|
||||
const { theme } = useTheme()
|
||||
|
||||
return status.in_reply_to_account_id &&
|
||||
return queryKey &&
|
||||
queryKey[1].page !== 'Toot' &&
|
||||
status.in_reply_to_account_id &&
|
||||
(status.mentions.length === 0 ||
|
||||
status.mentions.filter(
|
||||
mention => mention.id !== status.in_reply_to_account_id
|
||||
|
@ -7,7 +7,6 @@ const sentry = () => {
|
||||
log('log', 'Sentry', 'initializing')
|
||||
Sentry.init({
|
||||
dsn: Constants.manifest.extra.sentryDSN,
|
||||
environment: Constants.manifest.extra.toootEnvironment,
|
||||
enableInExpoDevelopment: false,
|
||||
debug:
|
||||
__DEV__ ||
|
||||
|
Loading…
Reference in New Issue
Block a user