Skip to content

Commit

Permalink
update README with comprehensive instructions for forking
Browse files Browse the repository at this point in the history
  • Loading branch information
alyssaruth committed May 8, 2024
1 parent 8d1b2bd commit 76e5ba0
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 10 deletions.
26 changes: 20 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ A simple soundboard app, with:
- 'Play random' floating action button, which will play a random quote of those returned by the current search
- Ability to share a quote (e.g. to WhatsApp) by long-pressing on it

## Setup
## Dev Setup

This project uses [asdf](https://asdf-vm.com/) to manage the necessary tools. To get set up, run
(from the root of the repo):
Expand All @@ -21,16 +21,30 @@ This project uses [asdf](https://asdf-vm.com/) to manage the necessary tools. To
./init-asdf.sh
```

This will prompt you to install asdf and set up the required plugins.
This will prompt you to install asdf and set up the required plugins. Once flutter is setup, run `flutter pub get` to grab the project dependencies.

## Data entry
## Making the App your own :art:

If you want to fork this project to make your own custom list of quotes, then you'll need:
If you want to fork this project to make your own soundboard, here are all the things you might want to change and how to do it.

- Some audio clips that you want to play, in MP3 format
- App icon: This project uses [flutter_launcher_icons](https://pub.dev/packages/flutter_launcher_icons) for this. To change it, edit the corresponding section in `pubspec.yaml` then run:

```bash
flutter pub run flutter_launcher_icons
```

- Splash screen: This project uses [flutter_native_splash](https://pub.dev/packages/flutter_native_splash). There is again a section of pubspec to update, after which you should run:

```bash
dart run flutter_native_splash:create
```

- App name: Search+replace the string YOUR_NAME_HERE
- Audio clips: These should be in mp3 format and added to the root of the assets/ folder
- Images for the clips.
- At least one per 'source' of audio, but can add more if you want more granularity than that
- Must be square, at least 200x200 pixels in size and in PNG format.
- Must be square, at least 200x200 pixels in size and in PNG format. Add to assets/images/
- Quote metadata is all joined up in `quotes_list.dart`

## Audio normalisation

Expand Down
2 changes: 1 addition & 1 deletion android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
FlutterApplication and put your custom class here. -->
<application
android:name="${applicationName}"
android:label="Soundboard"
android:label="YOUR_NAME_HERE"
android:icon="@mipmap/launcher_icon">
<activity
android:name="io.flutter.embedding.android.FlutterActivity"
Expand Down
2 changes: 1 addition & 1 deletion ios/Runner/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>Soundboard</string>
<string>YOUR_NAME_HERE</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
Expand Down
2 changes: 2 additions & 0 deletions lib/util/globals.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import 'package:audioplayers/audioplayers.dart';
import 'package:pocket_scat/util/file_sharer.dart';
import 'package:pocket_scat/util/quote.dart';

const APP_NAME = 'YOUR_NAME_HERE';

FileSharer fileSharer = FileSharer();
AudioPlayer audioPlayer = AudioPlayer();
Quote? quoteBeingShared;
2 changes: 1 addition & 1 deletion lib/widget/app.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class App extends StatelessWidget {
final theme = ThemeData(brightness: Brightness.dark, primaryColor: Colors.purple, hintColor: Colors.white70);

return MaterialApp(
title: 'Soundboard',
title: APP_NAME,
theme: theme.copyWith(colorScheme: theme.colorScheme.copyWith(secondary: Colors.purpleAccent)),
home: SearchableQuotes(_allQuotes));
}
Expand Down
3 changes: 2 additions & 1 deletion lib/widget/searchable_quotes.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import 'package:dart_random_choice/dart_random_choice.dart';
import 'package:flutter/material.dart';
import 'package:pocket_scat/util/quote.dart';

import '../util/globals.dart';
import 'quote_button.dart';

class SearchableQuotes extends StatefulWidget {
Expand Down Expand Up @@ -59,7 +60,7 @@ class SearchableQuotesState extends State<SearchableQuotes> {
),
style: const TextStyle(color: Colors.white));
} else {
return const Text('Soundboard');
return const Text(APP_NAME);
}
}

Expand Down

0 comments on commit 76e5ba0

Please sign in to comment.