Skip to content

Commit e1ea09e

Browse files
author
Kevin De Keyser
committed
Modified README.md and added documentation
1 parent 3018d72 commit e1ea09e

33 files changed

+11249
-36
lines changed

README.md

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,17 @@
1-
# Flutter app docset generation
1+
# Flutter docset generator script
22

3-
This is a slightly modified standard Flutter repo with a build.sh tool that generates a Dash compatible .docset documentation for the flutter app.
3+
This is a slightly modified standard Flutter repo with a [build.sh](./build.sh) tool that generates [docset](https://developer.apple.com/library/archive/documentation/DeveloperTools/Conceptual/Documentation_Sets/010-Overview_of_Documentation_Sets/docset_overview.html#//apple_ref/doc/uid/TP40005266-CH13-SW6) documentation for the Flutter app.
44

5-
Check out [build.sh] for more details.
5+
Docset is used by [Dash](https://kapeli.com/dash) and [Zeal](https://zealdocs.org) among others.
66

7-
# Install requirements
7+
# Install requirements / dependencies
8+
This script uses [dashing](https://github.com/technosophos/dashing), [jq](https://stedolan.github.io/jq) and [yq](https://github.com/mikefarah/yq).
9+
Optionally, python3 is needed with the [Pillow](https://pypi.org/project/Pillow/) package for resizing the image based on the iOS AppIcon of the current app.
10+
11+
You can install them using:
812
```
913
brew install dashing jq yq
14+
# Optional for image resizing:
15+
brew install python3
1016
pip3 install Pillow
1117
```
12-
13-
# Install instructions for optional flutter-stylizer:
14-
15-
```brew install go```
16-
Add the following 3 lines to your .zshrc (or .bashrc if you're using bash)
17-
```
18-
export GOPATH=${HOME}/go
19-
PATH=${PATH}:${HOME}/go/bin
20-
mkdir -p ${HOME}/go/bin
21-
```
22-
Finally, install using:
23-
`go get -u github.com/gmlewis/go-flutter-stylizer/cmd/flutter-stylizer`

build.sh

100644100755
Lines changed: 5 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,19 @@
11
#!/bin/sh
22

3-
# This script additionally needs:
3+
# This script additionally to flutter/dart needs:
44
# brew install dashing jq yq
5-
# [Optional]
6-
# For image resizing:
5+
# [Optional] For image resizing:
76
# pip3 install Pillow
8-
# Install instructions for flutter-stylizer:
9-
# brew install go
10-
# Add the following 3 lines to your .zshrc (or .bashrc if you're using bash)
11-
#
12-
# export GOPATH=${HOME}/go
13-
# PATH=${PATH}:${HOME}/go/bin
14-
# mkdir -p ${HOME}/go/bin
15-
#
16-
# Finally, install using: go get -u github.com/gmlewis/go-flutter-stylizer/cmd/flutter-stylizer
177

188
# Install/Update plugins
199
flutter pub get
2010

21-
# [Essential] Run code generation
22-
flutter pub run build_runner build --delete-conflicting-outputs
11+
# If your project uses code generation:
12+
# flutter pub run build_runner build --delete-conflicting-outputs
2313

2414
# Format the code, should be done on saving by IDE.
2515
flutter format .
2616

27-
# [Optional] Stylize flutter if installed: https://github.com/gmlewis/go-flutter-stylizer
28-
flutter-stylizer lib/...
29-
3017
# Run tests
3118
flutter test
3219

@@ -149,7 +136,6 @@ cd ..
149136
# [OPTIONAL] Set the docset language to dartlang.
150137
cat > preprocessing.dart <<- EOM
151138
import 'dart:io';
152-
import 'package:args/args.dart';
153139
154140
/// This changes the DocSetPlatformFamily key to be "dartlang" instead of the
155141
/// name of the package (usually "flutter").
@@ -177,12 +163,11 @@ void main(List<String> args) {
177163
}
178164
EOM
179165

180-
dart preprocessing.dart "$FLUTTERNAME.docset"
166+
dart run preprocessing.dart "$FLUTTERNAME.docset"
181167

182168
cd ..
183169

184170
# [OPTIONAL] Clean
185171
rm resize.py
186172
rm doc/preprocessing.dart
187173
rm doc/api/dashing.json
188-
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>CFBundleIdentifier</key>
6+
<string>flutterdashdocumentation</string>
7+
<key>CFBundleName</key>
8+
<string>flutterdashdocumentation</string>
9+
<key>DocSetPlatformFamily</key>
10+
<string>dartlang</string>
11+
<key>isDashDocset</key>
12+
<true/>
13+
<key>DashDocSetFamily</key>
14+
<string>dashtoc</string>
15+
<key>dashIndexFilePath</key>
16+
<string>index.html</string>
17+
<key>isJavaScriptEnabled</key><false/>
18+
</dict>
19+
</plist>
Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
<!DOCTYPE html><html lang="en"><head>
2+
<meta charset="utf-8"/>
3+
<meta http-equiv="X-UA-Compatible" content="IE=edge"/>
4+
<meta name="viewport" content="width=device-width, height=device-height, initial-scale=1, user-scalable=no"/>
5+
<meta name="generator" content="made with love by dartdoc 6.0.0"/>
6+
<meta name="description" content="flutterdashdocumentation API docs, for the Dart programming language."/>
7+
<title>flutterdashdocumentation - Dart API docs</title>
8+
9+
10+
11+
<link rel="preconnect" href="https://fonts.gstatic.com"/>
12+
<link href="https://fonts.googleapis.com/css2?family=Roboto+Mono:ital,wght@0,300;0,400;0,500;0,700;1,400&amp;display=swap" rel="stylesheet"/>
13+
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet"/>
14+
15+
<link rel="stylesheet" href="static-assets/github.css?v1"/>
16+
<link rel="stylesheet" href="static-assets/styles.css?v1"/>
17+
<link rel="icon" href="static-assets/favicon.png?v1"/>
18+
19+
20+
</head>
21+
22+
23+
<body data-base-href="" data-using-base-href="false">
24+
25+
<div id="overlay-under-drawer"></div>
26+
27+
<header id="title">
28+
<button id="sidenav-left-toggle" type="button">&nbsp;</button>
29+
<ol class="breadcrumbs gt-separated dark hidden-xs">
30+
<li class="self-crumb">flutterdashdocumentation package</li>
31+
</ol>
32+
<div class="self-name">flutterdashdocumentation</div>
33+
<form class="search navbar-right" role="search">
34+
<input type="text" id="search-box" autocomplete="off" disabled="" class="form-control typeahead" placeholder="Loading search..."/>
35+
</form>
36+
</header>
37+
38+
<main>
39+
40+
41+
<div id="dartdoc-main-content" class="main-content">
42+
<h1>404: Something&#39;s gone wrong :-(</h1>
43+
44+
<section class="desc">
45+
<p>You&#39;ve tried to visit a page that doesn&#39;t exist. Luckily this site
46+
has other <a href="index.html">pages</a>.</p>
47+
<p>If you were looking for something specific, try searching:
48+
</p><form class="search-body" role="search">
49+
<input type="text" id="search-body" autocomplete="off" disabled="" class="form-control typeahead" placeholder="Loading search..."/>
50+
</form>
51+
<p></p>
52+
53+
</section>
54+
</div> <!-- /.main-content -->
55+
56+
<div id="dartdoc-sidebar-left" class="sidebar sidebar-offcanvas-left">
57+
<header id="header-search-sidebar" class="hidden-l">
58+
<form class="search-sidebar" role="search">
59+
<input type="text" id="search-sidebar" autocomplete="off" disabled="" class="form-control typeahead" placeholder="Loading search..."/>
60+
</form>
61+
</header>
62+
63+
<ol class="breadcrumbs gt-separated dark hidden-l" id="sidebar-nav">
64+
<li class="self-crumb">flutterdashdocumentation package</li>
65+
</ol>
66+
67+
68+
<h5><span class="package-name">flutterdashdocumentation</span> <span class="package-kind">package</span></h5>
69+
<ol>
70+
<li class="section-title">Libraries</li>
71+
<li><a href="commented_floating_action_button/commented_floating_action_button-library.html">commented_floating_action_button</a></li>
72+
<li><a href="main/main-library.html">main</a></li>
73+
</ol>
74+
75+
</div>
76+
77+
<div id="dartdoc-sidebar-right" class="sidebar sidebar-offcanvas-right">
78+
</div>
79+
80+
</main>
81+
82+
<footer>
83+
<span class="no-break">
84+
flutterdashdocumentation
85+
1.0.0+1
86+
</span>
87+
88+
89+
</footer>
90+
91+
92+
93+
<script src="static-assets/highlight.pack.js?v1"></script>
94+
<script src="static-assets/docs.dart.js"></script>
95+
96+
97+
98+
99+
100+
101+
102+
</body></html>
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
[]

0 commit comments

Comments
 (0)