Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
## 1.0.0+2
- style: fix code style

## 1.0.0+1
- doc: images in readme

## 1.0.0
**BREAKING: **
* api request moved to service
* Doki is singleton now

## 0.0.1

* Testing upload
12 changes: 9 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
<img alt="Doki Dont kill my app!" src="https://raw.githubusercontent.com/zoocityboy/flutter_doki/main/assets/doki.png">

<picture id="github_header" style="display:block;">
<source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/zoocityboy/flutter_doki/main/assets/doki_dark.png">
<img alt="Doki Dont kill my app!" src="https://raw.githubusercontent.com/zoocityboy/flutter_doki/main/assets/doki.png">
</picture>
<img id="pubdev_header" style="display:none;" alt="Doki Dont kill my app!" src="https://raw.githubusercontent.com/zoocityboy/flutter_doki/main/assets/doki.png">

<br>

Developed by 🦏 [zoocityboy][zoocityboy_link]
Expand Down Expand Up @@ -60,11 +66,11 @@ DokiBadgeWidget(
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

-------------------

<picture>
<picture id="github_zoocityboy" style="display:block;">
<source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/zoocityboy/zoo_brand/main/styles/README/zoocityboy_light.png">
<img alt="Flutter developer Zoocityboy" src="https://raw.githubusercontent.com/zoocityboy/zoo_brand/main/styles/README/zoocityboy_dark.png">
</picture>
<img id="pubdev_zoocityboy" alt="Flutter developer Zoocityboy" src="https://raw.githubusercontent.com/zoocityboy/zoo_brand/main/styles/README/zoocityboy_dark.png">


[logo_black]:https://raw.githubusercontent.com/zoocityboy/zoo_brand/main/styles/README/zoocityboy_dark.png#gh-light-mode-only
Expand Down
37 changes: 32 additions & 5 deletions tool/publish.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,33 @@
#!/bin/sh
mv README.md README.md.bak
mv README_publish.md README.md
#!/bin/bash

# Make script exit on first error
set -e

# Store the script's directory
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
PROJECT_DIR="$(dirname "$SCRIPT_DIR")"

echo "📦 Preparing files for publishing..."

# Create temporary README for publishing
cp "$PROJECT_DIR/README.md" "$PROJECT_DIR/README.md.bak"

# Remove github-specific elements and comments
sed -i '' \
-e '/<!--github-->/,/<!--\^github-->/d' \
-e '/<picture id="github_.*>/,/<\/picture>/d' \
-e 's/id="pubdev_.*" style="display:none;"/id="pubdev_header"/' \
"$PROJECT_DIR/README.md"

# Commit changes
git commit -am "chore: prepare README.md for publishing."

echo "🚀 Publishing to pub.dev..."
flutter pub publish
mv README.md README_publish.md
mv README.md.bak README.md

echo "🧹 Cleaning up..."
# Restore original README
git reset --hard HEAD^1
# mv "$PROJECT_DIR/README.md.bak" "$PROJECT_DIR/README.md"

echo "✅ Published successfully!"
Loading