Skip to content

Commit

Permalink
(pop_pop): update docs/scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
jamieastley committed Jan 27, 2022
2 parents 0b2e512 + 29595e2 commit cc7c30b
Show file tree
Hide file tree
Showing 10 changed files with 110 additions and 11 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/pop_pop_analyze.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ on:
- ".github/workflows/pop_pop_analyze.yaml"

jobs:
analyze:
test:
defaults:
run:
working-directory: packages/pop_pop

runs-on: ubuntu-latest
runs-on: macos-11

steps:
- name: Checkout repository
Expand All @@ -30,3 +30,4 @@ jobs:

- run: flutter pub get
- run: flutter analyze
- run: flutter test --coverage
2 changes: 1 addition & 1 deletion .github/workflows/pop_pop_release.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: pop_pop_release
name: pop_pop

on:
push:
Expand Down
28 changes: 26 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,27 @@
# pop_pop
# <img src="docs/bubbles.png" alt="bubbles" width="30"/> pop_pop <img src="docs/bubbles.png" alt="bubbles" width="30"/>

A collection of packages which provide both the building blocks and prebuilt components to create a bubble popping game in Flutter.
<p align="left">
<a href="https://github.com/jamieastley/pop_pop/actions"><img src="https://github.com/jamieastley/pop_pop/workflows/pop_pop/badge.svg" alt="build"></a>
<a href="https://codecov.io/gh/jamieastley/pop_pop"><img src="https://codecov.io/gh/jamieastley/pop_pop/branch/master/graph/badge.svg" alt="codecov"></a>
<a href="https://opensource.org/licenses/MIT"><img src="https://img.shields.io/badge/license-MIT-purple.svg" alt="License: MIT"></a>
</p>

A collection of packages which provide both the building blocks and prebuilt components to create a bubble popping game in Flutter.

| Package | Pub |
| ------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------------------- |
| [pop_pop](https://github.com/jamieastley/pop_pop/tree/master/packages/pop_pop) | [![pub package](https://img.shields.io/pub/v/pop_pop.svg)](https://pub.dev/packages/pop_pop) |

---

## Examples

- Coming soon™

## Feedback/Suggestions?

- [Open an issue here](https://github.com/jamieastley/pop_pop/issues)

## Maintainers

- [@jamieastley](https://github.com/jamieastley)
Binary file added docs/bubbles.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions packages/pop_pop/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -77,3 +77,6 @@ build/
!**/ios/**/default.pbxuser
!**/ios/**/default.perspectivev3
!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages

# Misc
coverage/
21 changes: 18 additions & 3 deletions packages/pop_pop/README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
# pop_pop
# <img src="../../docs/bubbles.png" alt="bubbles" width="30"/> pop_pop <img src="../../docs/bubbles.png" alt="bubbles" width="30"/>

A package to provide flexible and extendable interfaces to build a bubble popping game in Flutter.
<p align="left">
<a href="https://pub.dev/packages/pop_pop"><img src="https://img.shields.io/pub/v/pop_pop.svg" alt="Pub"></a>
<a href="https://github.com/jamieastley/pop_pop/actions"><img src="https://github.com/jamieastley/pop_pop/workflows/pop_pop/badge.svg" alt="build"></a>
<a href="https://codecov.io/gh/jamieastley/pop_pop"><img src="https://codecov.io/gh/jamieastley/pop_pop/branch/master/graph/badge.svg" alt="codecov"></a>
<a href="https://opensource.org/licenses/MIT"><img src="https://img.shields.io/badge/license-MIT-purple.svg" alt="License: MIT"></a>
</p>

This package is implemented in [pop_pop_components](// TODO:), which provides some default game widgets and implementations out of the box.
A package to provide flexible and extendable interfaces to provide game logic, audio, game timers/countdowns and themeing to build a bubble popping game in Flutter.

## Getting Started

Expand All @@ -12,3 +17,13 @@ dependencies:

pop_pop: <version>
```
This package is implemented in [pop_pop_components](https://pub.dev/pop_pop_components), which provides some default game widgets and implementations out of the box, while still leaving flexibility to implement with your own state management solution.
## Feedback/Suggestions?
- [Open an issue here](https://github.com/jamieastley/pop_pop/issues)
## Maintainers
- [@jamieastley](https://github.com/jamieastley)
Binary file added packages/pop_pop/test/goldens/default_theme.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
56 changes: 56 additions & 0 deletions packages/pop_pop/test/pop_pop_bubble_theme_model_test.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:pop_pop/pop_pop.dart';

void main() {
group('PopPopBubbleThemeModel:', () {
testWidgets('Golden test', (tester) async {
const theme = PopPopBubbleTheme();
await tester.pumpWidget(MaterialApp(
home: Scaffold(
body: Row(
mainAxisSize: MainAxisSize.min,
children: [
Container(
height: theme.size,
width: theme.size,
decoration: BoxDecoration(color: theme.bubbleBaseColor),
),
Container(
height: theme.size,
width: theme.size,
decoration: BoxDecoration(
color: theme.bubbleBodyColor,
border: Border.all(
width: theme.strokeWidth,
color: Colors.black,
),
),
),
Container(
height: theme.size,
width: theme.size,
decoration: BoxDecoration(color: theme.bubbleRimColor),
),
Container(
height: theme.size,
width: theme.size,
decoration: BoxDecoration(color: theme.gridBackgroundColor),
),
Container(
height: theme.size,
width: theme.size,
decoration: BoxDecoration(color: theme.poppedBubbleBaseColor),
),
],
),
),
));

await expectLater(
find.byType(Row),
matchesGoldenFile('goldens/default_theme.png'),
);
});
});
}
4 changes: 2 additions & 2 deletions tools/bump_version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ if [ -f ${PACKAGE_PATH}/VERSION ]; then
read
echo "$PUSHING_MSG"
git add ${PACKAGE_PATH}/CHANGELOG.md ${PACKAGE_PATH}/VERSION ${PACKAGE_PATH}/pubspec.yaml &&
git commit -m "${1}-v${NEW_VERSION}" -m "- Update \`CHANGELOG.md\` and \`pubspec.yaml\`" &&
git commit -m "chore(${1}): v${NEW_VERSION}" -m "- Update \`CHANGELOG.md\` and \`pubspec.yaml\`" &&
git tag -a -m "${1}-v${NEW_VERSION}" "${1}-v${NEW_VERSION}"
else
echo "${WARNING_FLAG} Could not find a VERSION file."
Expand Down Expand Up @@ -107,7 +107,7 @@ else
read
echo "$PUSHING_MSG"
git add ${PACKAGE_PATH}/CHANGELOG.md ${PACKAGE_PATH}/VERSION ${PACKAGE_PATH}/pubspec.yaml &&
git commit -m "${1}-v0.1.0" -m "- Update \`CHANGELOG.md\` and \`pubspec.yaml\` " &&
git commit -m "chore(${1}): v0.1.0" -m "- Update \`CHANGELOG.md\` and \`pubspec.yaml\` " &&
git tag -a -m "${1}-v0.1.0" "${1}-v0.1.0"
fi
fi
Expand Down
2 changes: 1 addition & 1 deletion tools/generate_changelog.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if [[ $url =~ $re ]]; then

# Generates a markdown-friendly changelog by rendering commit hashes and JIRA project codes as hyperlinks.
# `$1` = commit to...from ref
git log --pretty=format:'<li> (<a href="https://github.com/'$user'/'$repo'/commits/%H">%h</a>) - %s</li> ' --no-merges $1
git log --pretty=format:'- %s' --no-merges $1
else
exit 1
fi

0 comments on commit cc7c30b

Please sign in to comment.