feat: initialize Flutter project with version management
- Initialize Flutter 3.38 project with all platforms - Add build-time version generation from pubspec.yaml - Print version to console on app startup - Create CHANGELOG.md following Keep a Changelog format - Update .gitignore for Flutter + generated files - Basic app scaffold with Material 3 theming 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,49 @@
|
||||
import 'dart:developer' as developer;
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import 'version.g.dart';
|
||||
|
||||
void main() {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
|
||||
developer.log(
|
||||
'${AppVersion.name} v${AppVersion.fullVersion}',
|
||||
name: 'tatlock_ui',
|
||||
);
|
||||
|
||||
runApp(const TatlockApp());
|
||||
}
|
||||
|
||||
class TatlockApp extends StatelessWidget {
|
||||
const TatlockApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return MaterialApp(
|
||||
title: 'Tatlock UI',
|
||||
theme: ThemeData(
|
||||
colorScheme: ColorScheme.fromSeed(seedColor: Colors.indigo),
|
||||
useMaterial3: true,
|
||||
),
|
||||
home: const HomePage(),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
class HomePage extends StatelessWidget {
|
||||
const HomePage({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
backgroundColor: Theme.of(context).colorScheme.inversePrimary,
|
||||
title: const Text('Tatlock UI'),
|
||||
),
|
||||
body: const Center(
|
||||
child: Text('Welcome to Tatlock UI'),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
// GENERATED FILE - DO NOT EDIT
|
||||
// Generated by: dart run tool/generate_version.dart
|
||||
|
||||
/// Application version information from pubspec.yaml
|
||||
class AppVersion {
|
||||
AppVersion._();
|
||||
|
||||
static const String name = 'tatlock_ui';
|
||||
static const String description = 'Tatlock - a Home Lab AI';
|
||||
static const String version = '0.1.0';
|
||||
static const int buildNumber = 1;
|
||||
static const String fullVersion = '0.1.0+1';
|
||||
}
|
||||
Reference in New Issue
Block a user