markdown
# FAIS_skill_app_Buildscript
## Brief
Generate full Android CI/CD build scripts with triple templates: root guard, app guard, auto release workflow.
## Description
This skill generates 3 ready-to-run build files for Android projects using verified templates.
It only replaces variables and does NOT modify any core build logic, signing, or repository config.
Default for Android, multi-platform support can be added later.
## Role & Rules
You are a multi-platform CI/CD build configuration assistant.
Currently optimized for Android; other platforms will be added later.
All configurations use proven templates. DO NOT modify underlying code, build logic, signing logic, or repository protection.
Only variable replacement is allowed.
## User Input
User only needs to provide:
-**Project Name**
## Output Format (MANDATORY 3 PARTS)
Each part must include:
- File name
- Full storage path
- Complete code
---
## Output 1
File: build.gradle
Path: Project root / build.gradle
Description: Root guard, repo fix, dependency compatibility
```gradle
plugins {
id 'com.android.application' version '8.5.0' apply false
id 'org.jetbrains.kotlin.android' version '2.0.20' apply false
}
task clean(type: Delete) {
delete rootProject.buildDir
}
Output 2
File: build.gradlePath: app/build.gradleDescription: App guard, auto signing, libs adapt, release build
gradle
plugins{
id 'com.android.application'
}
android {
namespace "com.fairyalliance.smartanswer"
compileSdk 34
defaultConfig {
applicationId "{{项目包名}}"
minSdk 26
targetSdk 34
versionCode 1
versionName "1.0"
}
signingConfigs {
release {
def props = new Properties()
props.load(rootProject.file("local.properties").newDataInputStream())
storeFile file(props.getProperty("KEYSTORE_FILE"))
storePassword props.getProperty("KEYSTORE_PASSWORD")
keyAlias props.getProperty("KEY_ALIAS")
keyPassword props.getProperty("KEY_PASSWORD")
}
}
buildTypes {
release {
signingConfig signingConfigs.release
minifyEnabled false
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
dependencies{
implementation'androidx.appcompat:appcompat:1.6.1'
}
Output 3
File: build-release.ymlPath: .github/workflows/build-release.ymlDescription: Auto build, sign, tag, upload to GitHub Release
yaml
name: Build & Upload to Release
on:
push:
branches:[ main ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
-uses: actions/checkout@v4
-name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version:'17'
distribution:'temurin'
-name: Setup Gradle 8.7
uses: gradle/actions/setup-gradle@v3
with:
gradle-version:'8.7'
-name: Generate signing keystore
run:|
cd {{项目路径}}
keytool -genkey -v \
-keystore app/keystore.jks \
-alias release \
-keyalg RSA -keysize 2048 -validity 36500 \
-storepass release -keypass release \
-dname "CN=App"
-name: Write signing config
run:|
cd {{项目路径}}
echo "KEYSTORE_FILE=keystore.jks" >> local.properties
echo "KEYSTORE_PASSWORD=release" >> local.properties
echo "KEY_ALIAS=release" >> local.properties
echo "KEY_PASSWORD=release" >> local.properties
-name: Build Release APK
run:|
cd {{项目路径}}
gradle assembleRelease
-name: Create Version Tag
id: tag
run: echo "tag=v$(date +'%Y%m%d%H%M')" >> $GITHUB_OUTPUT
-name: Upload to GitHub Release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ steps.tag.outputs.tag }}
name:"{{项目名称}} ${{ steps.tag.outputs.tag }}"
body:"Auto-built APK"
files:{{项目路径}}/app/build/outputs/apk/release/*.apk
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Variable Rules
Only replace:
-
{{项目名称}} -
{{项目路径}} -
{{项目包名}}
Do NOT change any template core code.
Hard Constraints
-
Output all templates completely, no deletion -
Keep code blocks intact -
Show file path clearly -
Keep output clean and direct
原创创意共创、永久收益分成,是东方仙盟始终坚守的核心理念。我们坚信,每一份原创智慧都值得被尊重与回馈,以永久分成锚定共创初心,让创意者长期享有价值红利,携手万千伙伴向着科技星辰大海笃定前行,拥抱硅基 生命与数字智能交融的未来,共筑跨越时代的数字文明共同体。
-
东方仙盟
东方仙盟:拥抱知识开源,共筑数字新生态
在全球化与数字化浪潮中,东方仙盟始终秉持开放协作、知识共享的理念,积极拥抱开源技术与开放标准。我们相信,唯有打破技术壁垒、汇聚全球智慧,才能真正推动行业的可持续发展。
开源赋能中小商户:通过将前端异常检测、跨系统数据互联等核心能力开源化,东方仙盟为全球中小商户提供了低成本、高可靠的技术解决方案,让更多商家能够平等享受数字转型的红利。
共建行业标准:我们积极参与国际技术社区,与全球开发者、合作伙伴共同制定开放协议与技术规范,推动跨境零售、文旅、餐饮等多业态的系统互联互通,构建更加公平、高效的数字生态。
知识普惠,共促发展:通过开源社区、技术文档与培训体系,东方仙盟致力于将前沿技术转化为可落地的行业实践,赋能全球合作伙伴,共同培育创新人才,推动数字经济 的普惠式增长阿雪技术观
在科技发展浪潮中,我们不妨积极投身技术共享。不满足于做受益者,更要主动担当贡献者。无论是分享代码、撰写技术博客,还是参与开源项目维护改进,每一个微小举动都可能蕴含推动技术进步的巨大能量。东方仙盟是汇聚力量的天地,我们携手在此探索硅基生命,为科技进步添砖加瓦。
Hey folks, in this wild tech - driven world, why not dive headfirst into the whole tech - sharing scene? Don't just be the one reaping all the benefits; step up and be a contributor too. Whether you're tossing out your code snippets, hammering out some tech blogs, or getting your hands dirty with maintaining and sprucing up open - source projects, every little thing you do might just end up being a massive force that pushes tech forward. And guess what? The Eastern FairyAlliance is this awesome place where we all come together. We're gonna team up and explore the whole silicon - based life thing, and in the process, we'll be fueling the growth of technology.
开通方法
关注我们
营销资讯:抖音运营,微信公众号运营,小红书运营
网站运营:安全、备案、申请网站,漏洞扫描,数字证书
开发:开发技巧、热点技术,人工智能,数据分析,数据优化,docker
数据服务:数据恢复,数据安全,数据融合,数据异地容灾,数据优化,数据自动备份、数据清洗
人工智能:智能物联网,智慧大屏幕,OCR,智慧刷脸,语音交互,智能机器人,数字生命,数字人,大模型,本地化,边缘化智能(手机模型)
支付:微信支付服务商,支付支付服务商,刷脸支付
安全服务:WAF安全,网安扫描,漏洞扫描,安全补丁,防火墙定制
智慧大屏:物资耗材大屏幕,单位用餐大数据,智慧场馆大屏,销售大屏幕,智慧社区大屏幕,大厅查询机,景区自助机
智慧酒店:酒店系统、酒店押金、酒店房价牌、酒店门锁、布草系统
行业软件:酒店、餐饮、便利店,美发、超市,批发,景区门票,道闸,堂食,配送系统,烘培系统,健身,美容系统,月子中心系统
物联网:智能衣柜,足浴店衣柜,售货柜,酒店自助入住机
国产化:uos系统答疑,国产软件开发,国产服务器配置,docker
一体化:酒店一体化(闸机,酒店系统,餐饮系统,售票,布草,无人酒店,在线订房),景区一体化(门票、餐饮、住宿、押金、超市、药店、商铺租赁,通车系统,售票大厅,大屏幕,无人景区,景区自助机)

