20250103在Ubuntu20.04.5的Android Studio 2024.2.1.12中跑通Hello World

news2025/1/8 19:43:57

20250103在Ubuntu20.04.5的Android Studio 2024.2.1.12中跑通Hello World
2025/1/3 14:06


百度:android studio helloworld
android studio hello world
kotlin helloword
kotlin 串口
no run configurations added
android studio  no run configurations added


1、需要更换gradle的源,不然肯定会编译报错的。
2、需要修改相关的配置源。或者想办法上外网。


Z:\AndroidStudioProjects\MyApplication\gradle\wrapper\gradle-wrapper.properties
#Thu Jan 02 17:37:42 CST 2025
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://mirrors.aliyun.com/macports/distfiles/gradle/gradle-8.9-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

修改为:
#Fri Jan 03 09:16:24 CST 2025
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
#distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-bin.zip
distributionUrl=https\://mirrors.cloud.tencent.com/gradle/gradle-8.9-all.zip

zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists


Z:\AndroidStudioProjects\MyApplication\settings.gradle.kts

pluginManagement {
    repositories {
        google {
            content {
                includeGroupByRegex("com\\.android.*")
                includeGroupByRegex("com\\.google.*")
                includeGroupByRegex("androidx.*")
            }
        }
        mavenCentral()
        gradlePluginPortal()
    }
}
dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
    repositories {
        google()
        mavenCentral()
    }
}

rootProject.name = "MyApplication"
include(":app")


修改为:

pluginManagement {
    repositories {
        maven { url = uri("https://maven.aliyun.com/repository/gradle-plugin") }
        maven { url = uri("https://maven.aliyun.com/repository/spring-plugin") }
        maven { url = uri("https://maven.aliyun.com/repository/public") }
        maven { url = uri("https://maven.aliyun.com/repository/google") }
        maven { url = uri("https://jitpack.io") }

        google {
            content {
                includeGroupByRegex("com\\.android.*")
                includeGroupByRegex("com\\.google.*")
                includeGroupByRegex("androidx.*")
            }
        }
        mavenCentral()
        gradlePluginPortal()
    }
}
dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
    repositories {
        maven { url = uri("https://maven.aliyun.com/repository/gradle-plugin") }
        maven { url = uri("https://maven.aliyun.com/repository/spring-plugin") }
        maven { url = uri("https://maven.aliyun.com/repository/public") }
        maven { url = uri("https://maven.aliyun.com/repository/google") }
        maven { url = uri("https://jitpack.io") }

        google()
        mavenCentral()
    }
}

rootProject.name = "My Application"
include(":app")


https://blog.csdn.net/WeiHao0240/article/details/141564065?ops_request_misc=%257B%2522request%255Fid%2522%253A%2522f0b56d2343808885d68f86545ea44725%2522%252C%2522scm%2522%253A%252220140713.130102334.pc%255Fall.%2522%257D&request_id=f0b56d2343808885d68f86545ea44725&biz_id=0&utm_medium=distribute.pc_search_result.none-task-blog-2~all~first_rank_ecpm_v1~rank_v31_ecpm-1-141564065-null-null.142^v100^pc_search_result_base2&utm_term=Android%20studio2024%20%E6%9C%80%E6%96%B0%E7%89%88%20hello%20world&spm=1018.2226.3001.4187

https://blog.csdn.net/WeiHao0240/article/details/141564065
Android Studio 2024最新版Hello World

https://blog.csdn.net/weixin_33709609/article/details/92507468?utm_medium=distribute.pc_relevant.none-task-blog-2~default~baidujs_baidulandingword~default-0-92507468-blog-133556908.235^v43^pc_blog_bottom_relevance_base7&spm=1001.2101.3001.4242.1&utm_relevant_index=3
第2章 快速开始:HelloWorld 《Kotlin 极简教程》


https://blog.csdn.net/universsky2015/article/details/108669147
《Kotlin 极简教程 》第2章 快速开始:HelloWorld


https://jingyan.baidu.com/article/6525d4b180d542ac7c2e9447.html
Kotlin入门教程-1.2、编写第一句程序HelloWorld


https://blog.csdn.net/m0_67830223/article/details/140501450
【移动应用开发】创建Hello World应用


https://blog.csdn.net/qq_74706597/article/details/143842946
有关Android Studio的安装与配置并实现helloworld(有jdk的安装与配置)(保姆级教程)


https://www.cnblogs.com/GiveCookies/p/18476200
windows安装Android studio并运行显示"hello world"
这里推荐清华的镜像, 其他的镜像可在网上查找


https://blog.csdn.net/github_74110837/article/details/143092695
Android Studio 2024版本新建项目换源教程


 

ubuntu中的firefox下的参考资料:

https://blog.csdn.net/WeiHao0240/article/details/141564065
Android Studio 2024最新版Hello World


https://blog.csdn.net/qq_17470165/article/details/80686353
【Android Kotlin】Android Studio创建一个简单的Kotlin应用

https://blog.csdn.net/qq_44512238/article/details/139828163
【Android】不能下载Gradle的解决方法Could not install Gradle distribution from ‘https:services.gradle.orgdistrib


https://www.cnblogs.com/IDM2025/p/18401984
解决Android Studio不能下载Gradle的教程Could not install Gradle distribution from ‘https:services.gradle.orgdistrib


https://blog.csdn.net/qq_42257666/article/details/117398185
ERROR: Could not install Gradle distribution from ‘https://services.gradle.org/distributions/gradle


android studio hello world

https://cloud.tencent.com/developer/information/%E5%A6%82%E4%BD%95%E5%9C%A8Android%20Studio%E4%B8%AD%E5%88%B6%E4%BD%9CJNI%20hello%20world%E7%A8%8B%E5%BA%8F%EF%BC%9F
如何在Android Studio中制作JNI hello world程序?


https://gitcode.csdn.net/662760cec46af92642763710.html?dp_token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpZCI6MjQwNTYwLCJleHAiOjE3MzYxNjYxNDcsImlhdCI6MTczNTU2MTM0NywidXNlcm5hbWUiOiJ3YjQ5MTYifQ.JPTaol3eBK8hBCtlfiGdxqxPK1Hjk1mAjF1HJp9f6qE&spm=1001.2101.3001.6650.5&utm_medium=distribute.pc_relevant.none-task-blog-2%7Edefault%7EBlogCommendFromBaidu%7Eactivity-5-133266830-blog-141564065.235%5Ev43%5Epc_blog_bottom_relevance_base7&depth_1-utm_source=distribute.pc_relevant.none-task-blog-2%7Edefault%7EBlogCommendFromBaidu%7Eactivity-5-133266830-blog-141564065.235%5Ev43%5Epc_blog_bottom_relevance_base7&utm_relevant_index=10
Android Studio安装和使用教程(全文图解)


ubuntu android studio gradle-8.9-all.zip yuantou
Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-8.9-bin.zip'.
ould not install Gradle distribution from 'https://services.gradle.org/dist
Unable to find Gradle tasks to build: []. Build mode: REBUILD.


https://blog.csdn.net/weixin_47617631/article/details/143760018
androidstudio入门到放弃配置

https://mirrors.cloud.tencent.com/gradle//gradle-8.9-all.zip


https://blog.csdn.net/qq_42257666/article/details/117398185
ERROR: Could not install Gradle distribution from ‘https://services.gradle.org/distributions/gradle


https://www.cnblogs.com/IDM2025/p/18401984
解决Android Studio不能下载Gradle的教程Could not install Gradle distribution from ‘https:services.gradle.orgdistrib 


https://blog.csdn.net/qq_44512238/article/details/139828163
【Android】不能下载Gradle的解决方法Could not install Gradle distribution from ‘https:services.gradle.orgdistrib

https://blog.csdn.net/rcAndroid/article/details/120717102
Unable to find gradle task to build

https://www.cnblogs.com/wanglongjiang/p/17403741.html
Unable to find Gradle tasks to build: [:]. Build mode: ASSEMBLE. Tests: None

https://wenku.csdn.net/answer/7ad82f228a644c5894e56f39d190e6e5
Unable to find Gradle tasks to build [ ]. Build mode ASSEMBLE. Tests None - CSDN文库.html


https://blog.51cto.com/u_16213299/7126853
Unable to find Gradle tasks to build: [:app]. Build mode: COMPILE_JAVA. Test


https://blog.csdn.net/Frankfan666/article/details/143225400
Android:Unable to find Gradle tasks to build: [:app]. Build mode: ASSEMBLE.

Download https://maven.aliyun.com/repository/gradle-plugin/com/android/tools/build/transform-api/2.0.0-deprecated-use-gradle-api/transform-api-2.0.0-deprecated-use-gradle-api.pom, took 123 ms
Download https://maven.aliyun.com/repository/gradle-plugin/org/tensorflow/tensorflow-lite-metadata/0.1.0-rc2/tensorflow-lite-metadata-0.1.0-rc2.pom, took 146 ms
Download https://maven.aliyun.com/repository/gradle-plugin/org/apache/httpcomponents/httpcomponents-parent/10/httpcomponents-parent-10.pom, took 345 ms
Download https://maven.aliyun.com/repository/gradle-plugin/org/apache/apache/18/apache-18.pom, took 130 ms
Download https://maven.aliyun.com/repository/gradle-plugin/org/jetbrains/annotations/13.0/annotations-13.0.pom, took 122 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/errorprone/error_prone_annotations/2.3.1/error_prone_annotations-2.3.1.pom, took 120 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/auto/auto-parent/6/auto-parent-6.pom, took 124 ms
Download https://maven.aliyun.com/repository/gradle-plugin/commons-codec/commons-codec/1.10/commons-codec-1.10.pom, took 150 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/guava/failureaccess/1.0.1/failureaccess-1.0.1.pom, took 123 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/guava/listenablefuture/9999.0-empty-to-avoid-conflict-with-guava/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.pom, took 235 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/guava/guava-parent/26.0-android/guava-parent-26.0-android.pom, took 117 ms
Download https://maven.aliyun.com/repository/gradle-plugin/org/apache/commons/commons-parent/42/commons-parent-42.pom, took 151 ms
Download https://maven.aliyun.com/repository/gradle-plugin/javax/inject/javax.inject/1/javax.inject-1.jar, took 418 ms
Download https://maven.aliyun.com/repository/gradle-plugin/net/sf/kxml/kxml2/2.3.0/kxml2-2.3.0.jar, took 571 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/auto/value/auto-value-annotations/1.6.2/auto-value-annotations-1.6.2.jar, took 196 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/guava/listenablefuture/9999.0-empty-to-avoid-conflict-with-guava/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar, took 127 ms
> Task :prepareKotlinBuildScriptModel UP-TO-DATE
Download https://maven.aliyun.com/repository/gradle-plugin/javax/inject/javax.inject/1/javax.inject-1-sources.jar, took 119 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/auto/value/auto-value-annotations/1.6.2/auto-value-annotations-1.6.2-sources.jar, took 172 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/guava/listenablefuture/1.0/listenablefuture-1.0.pom, took 129 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/squareup/javawriter/2.1.1/javawriter-2.1.1.pom, took 161 ms
Download https://maven.aliyun.com/repository/gradle-plugin/org/hamcrest/hamcrest-parent/1.3/hamcrest-parent-1.3.pom, took 354 ms
Download https://maven.aliyun.com/repository/gradle-plugin/com/google/guava/listenablefuture/1.0/listenablefuture-1.0.jar, took 283 ms

BUILD SUCCESSFUL in 4m 57s

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/2272788.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

卸载干净 IDEA(图文讲解)

目录 1、卸载 IDEA 程序 2、注册表清理 3、残留清理 1、卸载 IDEA 程序 点击屏幕左下角 Windows 图标 -> 设置-控制面板->intellij idea 勾选第一栏 Delete IntelliJ IDEA 2022.2 caches and local history,表示同时删除 IDEA 本地缓存以及历史。 Delete I…

【HarmonyOS】鸿蒙应用实现屏幕录制详解和源码

【HarmonyOS】鸿蒙应用实现屏幕录制详解和源码 一、前言 官方文档关于屏幕录制的API和示例介绍获取简单和突兀。使用起来会让上手程度变高。所以特意开篇文章,讲解屏幕录制的使用。官方文档参见:使用AVScreenCaptureRecorder录屏写文件(ArkTS) 二、方…

我的创作纪念日——《惊变128天》

我的创作纪念日——《惊变128天》 机缘收获日常成就憧憬 机缘 时光飞逝,转眼间,我已在这条创作之路上走过了 128 天。回顾起 2024 年 8 月 29 日,我满怀忐忑与期待,撰写了第一篇技术博客《讲解LeetCode第1题:两数之和…

stm32第一次烧录或者上电运行卡死问题分析

问题描述 单片机烧录代码(刚上电)无法立即运行,必须要复位一次或多次才能运行;跟踪调试会进入HardFault_Handler中断。 问题分析 烧录配置如下图,首先排除配置问题那么该问题就比较让人头大了,理论上&am…

YOLOV8训练好的best.pt模型转best.onnx并部署成python可调用

今天这篇博文是学习大佬作品以后,执行我的需求后的总结,做了一些代码调整,就此记录一下,非常感谢大佬提供如此好的输出。 已知yolov8 训练好的模型一般是pt格式,比如best.pt,现在我期望这个模型可以转成可以…

君正T41交叉编译ffmpeg、opencv并做h264软解,利用君正SDK做h264硬件编码

目录 1 交叉编译ffmpeg----错误解决过程,不要看 1.1 下载源码 1.2 配置 1.3 编译 安装 1.3.1 报错:libavfilter/libavfilter.so: undefined reference to fminf 1.3.2 报错:error: unknown type name HEVCContext; did you mean HEVCPr…

基于ASP.NET的动漫网站

一、系统架构与技术实现 系统架构:基于ASP.NET的MVC框架构建,实现网站的层次结构,使得网站更加易于维护和扩展。 技术实现:利用ASP.NET的技术特点,如强大的后端开发能力、丰富的UI控件等,结合前端技术如HT…

「Java 数据结构全面解读」:从基础到进阶的实战指南

「Java 数据结构全面解读」:从基础到进阶的实战指南 数据结构是程序设计中的核心部分,用于组织和管理数据。Java 提供了丰富的集合框架和工具类,涵盖了常见的数据结构如数组、链表、栈、队列和树等。本文将系统性地介绍这些数据结构的概念、…

安卓NDK视觉开发——手机拍照文档边缘检测实现方法与库封装

一、项目创建 创建NDK项目有两种方式,一种从新创建整个项目,一个在创建好的项目添加NDK接口。 1.创建NDK项目 创建 一个Native C项目: 选择包名、API版本与算法交互的语言: 选择C版本: 创建完之后,可…

MATLAB仿真:基于GS算法的经大气湍流畸变涡旋光束波前校正仿真

GS算法流程 GS(Gerchberg-Saxton)相位恢复算法是一种基于傅里叶变换的最速下降算法,可以通过输出平面和输入平面上光束的光强分布计算出光束的相位分布。图1是基于GS算法的涡旋光束畸变波前校正系统框图,在该框图中,已…

【React+TypeScript+DeepSeek】穿越时空对话机

引言 在这个数字化的时代,历史学习常常给人一种距离感。教科书中的历史人物似乎永远停留在文字里,我们无法真正理解他们的思想和智慧。如何让这些伟大的历史人物"活"起来?如何让历史学习变得生动有趣?带着这些思考&…

深入刨析数据结构之排序(上)

目录 1.内部排序 1.1概述 1.2插入排序 1.2.1其他插入排序 1.2.1.1 折半插入排序 1.2.1.2 2-路插入排序 1.3希尔排序 1.4快速排序 1.4.1起泡排序 1.4.2快速排序 1.4.2.1hoare版本 1.4.2.2挖坑版本 1.4.2.3前后指针版本 1.4.2.4优化版本 1.4.2.4.1小区间插入排序优…

AIA - APLIC之三(附APLIC处理流程图)

本文属于《 RISC-V指令集基础系列教程》之一,欢迎查看其它文章。 1 APLIC复位 APLIC复位后,其所有状态都变得有效且一致,但以下情况除外: 每个中断域的domaincfg寄存器(spec第 4.5.1 节);可能是machine-level interrupt domain的MSI地址配置寄存器(spec第4.5.3 和4.5…

openwrt 清缓存命令行

一、查看缓存 : free -m 二、清缓存:echo 3 > /proc/sys/vm/drop_caches  三、详解。 释放物理页缓存 echo 1 > /proc/sys/vm/drop_caches 释放可回收的slab对象,包含inode and dentry echo 2 > /proc/sys/vm/drop_caches 同时…

Linux -- 端口号、套接字、网络字节序、sockaddr 结构体

目录 什么是端口号? 什么是套接字? 网络字节序 struct sockaddr 结构体 什么是端口号? 我们日常上网的时候,主机其实是在进行两种操作: 1、把远端的数据拉取到本地,比如刷抖音的时候,手机向…

《数据结构》期末考试测试题【中】

《数据结构》期末考试测试题【中】 21.循环队列队空的判断条件为?22. 单链表的存储密度比1?23.单链表的那些操作的效率受链表长度的影响?24.顺序表中某元素的地址为?25.m叉树第K层的结点数为?26. 在双向循环链表某节点…

实际开发中,常见pdf|word|excel等文件的预览和下载

实际开发中,常见pdf|word|excel等文件的预览和下载 背景相关类型数据之间的转换1、File转Blob2、File转ArrayBuffer3、Blob转ArrayBuffer4、Blob转File5、ArrayBuffer转Blob6、ArrayBuffer转File 根据Blob/File类型生成可预览的Base64地址基于Blob类型的各种文件的下载各种类型…

《Opencv》基础操作详解(4)

接上篇:《Opencv》基础操作详解(3)-CSDN博客 目录 22、图像形态学操作 (1)、顶帽(原图-开运算) 公式: 应用场景: 代码示例: (2)…

大数据高级ACP学习笔记(2)

钻取:变换维度的层次,改变粒度的大小 星型模型 雪花模型 MaxCompute DataHub

尚硅谷· vue3+ts 知识点学习整理 |14h的课程(持续更ing)

vue3 主要内容 核心:ref、reactive、computed、watch、生命周期 常用:hooks、自定义ref、路由、pinia、miit 面试:组件通信、响应式相关api ----> 笔记:ts快速梳理;vue3快速上手.pdf 笔记及大纲 如下&#xff…