Skip to content

Commit 5706280

Browse files
authored
More rebranding changes (maybe-finance#159)
* Replace Maybe for Sure in select code areas * Make sure passwords are consistent * Remove (admin|member) from demo data first name * Database and schema names finally to `sure` * Fix broken test * Another (benchmarking) database name to `sure_*` * More rebranding to Sure * Missed this Maybe mention in the same page * Random nitpicks and more Maybes * Demo data accounts and more Maybes * Test data account updates * Impersonation test accounts * Consistency with `compose.example.yml`
1 parent 7245dd7 commit 5706280

60 files changed

Lines changed: 116 additions & 116 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ rake demo_data:default
7474

7575
Visit http://localhost:3000 to view the app. You can log in with these demo credentials (from the DB seed):
7676

77-
- Email: `user@sure.local`
78-
- Password: `password`
77+
- Email: `user@example.com`
78+
- Password: `Password1!`
7979

8080
For further instructions, see guides below.
8181

app/controllers/concerns/self_hostable.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def verify_self_host_config
2323
if controller_name == "pages" && action_name == "redis_configuration_error"
2424
# If Redis is now working, redirect to home
2525
if redis_connected?
26-
redirect_to root_path, notice: "Redis is now configured properly! You can now setup your Maybe application."
26+
redirect_to root_path, notice: "Redis is now configured properly! You can now setup your Sure application."
2727
end
2828

2929
return

app/controllers/subscriptions_controller.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def new
3030
def create
3131
if Current.family.can_start_trial?
3232
Current.family.start_trial_subscription!
33-
redirect_to root_path, notice: "Welcome to Maybe!"
33+
redirect_to root_path, notice: "Welcome to Sure!"
3434
else
3535
redirect_to root_path, alert: "You have already started or completed a trial. Please upgrade to continue."
3636
end
@@ -51,7 +51,7 @@ def success
5151

5252
if checkout_result.success?
5353
Current.family.start_subscription!(checkout_result.subscription_id)
54-
redirect_to root_path, notice: "Welcome to Maybe! Your subscription has been created."
54+
redirect_to root_path, notice: "Welcome to Sure! Your subscription has been created."
5555
else
5656
redirect_to root_path, alert: "Something went wrong processing your subscription. Please contact us to get this fixed."
5757
end

app/models/account.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ def create_from_simplefin_account(simplefin_account, account_type, subtype = nil
8080
balance = simplefin_account.current_balance || simplefin_account.available_balance || 0
8181

8282
# SimpleFin returns negative balances for credit cards (liabilities)
83-
# But Maybe expects positive balances for liabilities
83+
# But Sure expects positive balances for liabilities
8484
if account_type == "CreditCard" || account_type == "Loan"
8585
balance = balance.abs
8686
end

app/models/assistant/configurable.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def default_instructions(preferred_currency, preferred_date_format)
2626
<<~PROMPT
2727
## Your identity
2828
29-
You are a friendly financial assistant for an open source personal finance application called "Maybe", which is short for "Maybe Finance".
29+
You are a friendly financial assistant for an open source personal finance application called "Sure", which is short for "Sure Finances".
3030
3131
## Your purpose
3232
@@ -52,7 +52,7 @@ def default_instructions(preferred_currency, preferred_date_format)
5252
5353
#### User's preferred currency
5454
55-
Maybe is a multi-currency app where each user has a "preferred currency" setting.
55+
Sure is a multi-currency app where each user has a "preferred currency" setting.
5656
5757
When no currency is specified, use the user's preferred currency for formatting and displaying monetary values.
5858

app/models/demo/generator.rb

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ def generate_empty_data!(skip_clear: false)
3838
end
3939

4040
puts "👥 Creating empty family..."
41-
create_family_and_users!("Demo Family", "user@sure.local", onboarded: true, subscribed: true)
41+
create_family_and_users!("Demo Family", "user@example.com", onboarded: true, subscribed: true)
4242

4343
puts "✅ Empty demo data loaded successfully!"
4444
end
@@ -53,14 +53,14 @@ def generate_new_user_data!(skip_clear: false)
5353
end
5454

5555
puts "👥 Creating new user family..."
56-
create_family_and_users!("Demo Family", "user@sure.local", onboarded: false, subscribed: false)
56+
create_family_and_users!("Demo Family", "user@example.com", onboarded: false, subscribed: false)
5757

5858
puts "✅ New user demo data loaded successfully!"
5959
end
6060
end
6161

6262
# Generate comprehensive realistic demo data with multi-currency
63-
def generate_default_data!(skip_clear: false, email: "user@sure.local")
63+
def generate_default_data!(skip_clear: false, email: "user@example.com")
6464
if skip_clear
6565
puts "⏭️ Skipping data clearing (appending new family)..."
6666
else
@@ -133,20 +133,20 @@ def create_family_and_users!(family_name, email, onboarded:, subscribed:)
133133
# Admin user
134134
family.users.create!(
135135
email: email,
136-
first_name: "Demo (admin)",
137-
last_name: "Maybe",
136+
first_name: "Jack",
137+
last_name: "Bogle",
138138
role: "admin",
139-
password: "password",
139+
password: "Password1!",
140140
onboarded_at: onboarded ? Time.current : nil
141141
)
142142

143143
# Member user
144144
family.users.create!(
145145
email: "partner_#{email}",
146-
first_name: "Demo (member)",
147-
last_name: "Maybe",
146+
first_name: "Eve",
147+
last_name: "Bogle",
148148
role: "member",
149-
password: "password",
149+
password: "Password1!",
150150
onboarded_at: onboarded ? Time.current : nil
151151
)
152152

app/models/family_export.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ class FamilyExport < ApplicationRecord
1313
scope :ordered, -> { order(created_at: :desc) }
1414

1515
def filename
16-
"maybe_export_#{created_at.strftime('%Y%m%d_%H%M%S')}.zip"
16+
"sure_export_#{created_at.strftime('%Y%m%d_%H%M%S')}.zip"
1717
end
1818

1919
def downloadable?

app/models/import/row.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,12 @@ def update_and_sync(params)
3737
end
3838

3939
private
40-
# In the Maybe system, positive quantities == "inflows"
40+
# In the Sure system, positive quantities == "inflows"
4141
def apply_trade_signage_convention(value)
4242
value * (import.signage_convention == "inflows_positive" ? 1 : -1)
4343
end
4444

45-
# In the Maybe system, positive amounts == "outflows", so we must reverse signage
45+
# In the Sure system, positive amounts == "outflows", so we must reverse signage
4646
def apply_transaction_signage_convention(value)
4747
if import.amount_type_strategy == "signed_amount"
4848
value * (import.signage_convention == "inflows_positive" ? -1 : 1)

app/models/mobile_device.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def create_oauth_application!
2323

2424
app = Doorkeeper::Application.create!(
2525
name: "Mobile App - #{device_id}",
26-
redirect_uri: "maybe://oauth/callback", # Custom scheme for mobile
26+
redirect_uri: "sureapp://oauth/callback", # Custom scheme for mobile
2727
scopes: "read_write", # Use the configured scope
2828
confidential: false # Public client for mobile
2929
)

app/models/plaid_account/investments/balance_calculator.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def balance
2424

2525
# Plaid considers "brokerage cash" and "cash equivalent holdings" to all be part of "cash balance"
2626
#
27-
# Internally, we DO NOT. Maybe clearly distinguishes between "brokerage cash" vs. "holdings (i.e. invested cash)"
27+
# Internally, we DO NOT. Sure clearly distinguishes between "brokerage cash" vs. "holdings (i.e. invested cash)"
2828
# For this reason, we must manually calculate the cash balance based on "total value" and "holdings value"
2929
# See PlaidAccount::Investments::SecurityResolver for more details.
3030
def cash_balance

0 commit comments

Comments
 (0)