Skip to content

Instantly share code, notes, and snippets.

View adityadroid's full-sized avatar
🎯
Fluttering around.

Aditya Gurjar adityadroid

🎯
Fluttering around.
View GitHub Profile
@adityadroid
adityadroid / flutter_extension_methods.dart
Created June 28, 2023 07:31 — forked from SashaKryzh/flutter_extension_methods.dart
List of my favorite extension methods in Flutter.
import 'package:flutter/material.dart';
extension BuildContextExtensions on BuildContext {
ThemeData get theme => Theme.of(this);
TextTheme get textTheme => theme.textTheme;
ColorScheme get colorScheme => theme.colorScheme;
DefaultTextStyle get defaultTextStyle => DefaultTextStyle.of(this);
name: monorepo_example
packages:
- packages/*
- apps/*
scripts:
analyze:
exec: dart analyze .
generate-run-config:
#!/bin/bash
# Function to copy and modify the run configuration files
copy_run_configs() {
local app_name="$1"
local source_dir="./apps/$app_name/.idea/runConfigurations"
local destination_dir="./.idea/runConfigurations"
# Create destination directory if it doesn't exist
mkdir -p "$destination_dir"
#!/bin/bash
# Function to copy and modify the run configuration files
copy_run_configs() {
local app_name="$1"
local source_dir="./apps/$app_name/.idea/runConfigurations"
local destination_dir="./.idea/runConfigurations"
# Create destination directory if it doesn't exist
mkdir -p "$destination_dir"
melos boostrap
cd packages
very_good create flutter_package bk_ticketing --desc "Ticketing package"
very_good create flutter_package bk_customers --desc "Customers package"
very_good create flutter_package bk_ui_kit --desc "UI Kit package"
very_good create dart_package bk_utilities --desc "Utilities package"
cd apps
very_good create flutter_app booking_app --desc "Just another booking app" --application-id "com.adityadroid.booking"
very_good create flutter_app merchant_app --desc "Just another merchant app" --application-id "com.adityadroid.merchant"
name: monorepo_example
packages:
- packages/*
- apps/*
scripts:
analyze:
exec: dart analyze .
name: monorepo_example
environment:
sdk: '>=2.18.0 <3.0.0'
dev_dependencies:
melos: ^3.0.1
firebase-test-lab-run:
steps:
- activate-ssh-key@4: {}
- git-clone@8: {}
- flutter-installer@0:
inputs:
- version: 3.3.10
- is_update: 'false'
- [email protected]:
inputs: