有办法删除一个模块在Android工作室? 当我右键单击一个模块,我找不到删除选项,是在其他地方吗?


当前回答

假设:

你正在使用Android Studio 1.2.1或1.2.2(我还没有最新的版本,当我这样做时,我会再次编辑它)。 您的项目工具窗口显示以下视图之一:“项目”,“包”,“Android”或“项目文件”

删除Android Studio模块的操作如下:

In the Project Tool Window click the module you want to delete. Between the Tool Bar and the Project Tool Window the tool bar you will see two "chips" that represent the path to the selected module, similar to: your-project-name > selected-module-name Right click on the selected-module-name chip. A context menu with multiple sections will appear. In the third section from the bottom there will be a section that contains "Reformat Code..", "Optimize Imports..." and "Delete". Select "Delete" and follow any prompts.

其他回答

删除文件>文件结构>依赖> -按钮。然后,如果它是静止的,你可以删除模块进入设置。Gradle文件,并从包含行中删除它。

(编者注:这个答案在2013年5月的Android Studio v0.1中是正确的,但在2014年7月不再准确,因为提到的菜单选项已经不存在了——请参阅最新的替代答案)。

首先你得把它标记为排除。 然后右键单击,就可以删除项目了。

正如我所看到的,在Android Studio 0.5.1中,你必须通过简单地执行File ->关闭项目来关闭项目,然后将鼠标移动到你想要删除的项目上,然后将鼠标保持在同一个项目上,然后按delete,然后单击“OK”按钮,这将从Android Studio中删除你的项目。

删除是件让人头疼的事。我发布了Android Studio 1.0.2的解决方案。

步骤1:右键单击从文件夹层次结构中选择的“项目名称”,如图所示。注意:通过右键单击项目名称并从上下文菜单中选择delete,也可以从窗口右侧的指挥官视图中删除它。

第二步:项目被删除了(看起来),但gradle似乎保留了项目应用文件夹的记录(通过点击gradle View查看)。现在转到文件->关闭项目。

步骤3:现在您处于开始窗口。在最近项目列表上移动光标。按下删除。

第四步:通过移动或删除文件夹从资源管理器中删除。这个位置是在your_user_name->Android Studio Projects->…

第五步:回到Android工作室窗口,项目就永远消失了。你现在可以开始一个新项目了。

如果你想手动删除(对我来说更容易),请遵循以下步骤:

让我们以“teste”为例。

1 -首先将资源管理器更改为“项目”,并打开“settings.gradle”;

2 -删除你想要的模块;

3 -转到项目的根文件夹,删除模块文件夹。