I am using AndroidStudio whenever I create projects, I always have to add dependencies, create BaseClass,etc... Very boring process. So, how can I make a template Flutter Project in AndroidStudio
You can create a template for Dart files doing the following:
File -> New -> Edit File Templates... -> Dart File
Though I think that's not exactly what you want, the easiest way I know would be having a base project and just replacing the files with a copy of that when you create a new project.
EDIT: Just found this article, maybe it can be helpful: https://medium.com/flutter-community/flutter-changing-the-default-app-template-f3448386139f
If you want to create a flutter app template then, you can run flutter create command in
'./{your-flutter-install}/packages/flutter-tools/templates/app/' location.
Or if you want a full-fledged template with numerous modern and intuitive UI screens and functionalities, you can check out lots of flutter templates out there in the market.
Related
I'm coming from the Visual Studio world of solutions, where each solution can consist of multiple projects that can refer to each other.
What I want to do is create a modular Android project in Android Studio such that all my code doesn't live in one huge app project. However, it seems terribly difficult to do this, so much so that I am sure I am doing something wrong.
I created a blank project called MyProject. This creates a project with the name MyProject and a package com.sohum.myproject. There is a single app project contained within containing no source files.
I now want to add another module under the same namespace (e.g. com.sohum.myproject.library1). However, it seems when I try to add a new module via the menu, I can only do so into a com.sohum.library1 project. How do I get it to use the same package as the project?
My end goal is to have all my modules under the com.sohum.myproject package, referencing each other. For example:
com.sohum.myproject.application will be the entry point. It might depend on com.sohum.myproject.library1 and com.sohum.myproject.someotherlibrary. And I would like to see all of these modules when I open the MyProject file.
You can click File > New > New Module. Then choose Android Library and enter the details.
Reference: https://developer.android.com/studio/projects/android-library
Another way is to set up the project in a subpackage when creating it.
For example, create a project MyProject in a root directory. Call the application Application and rename the package to be com.sohum.myproject.app instead of just com.sohum.myproject. Now any new modules created will be added below the com.sohum.myproject package space.
I use orchard source code and want rename solution for fast switching between different projects. But when I changed solution name, and created new module via Orchard.CodeGeneration module, my solution not reloaded and I must include new module to solution explicitly (RMC to Modules folder -> Add -> Existing Project...). When I added to module .chtml files, intellisense not working correctly (dont see html helplers or Model property, etc.). If I try compile, all worked good, without errors.
If I rename solution back to "Orchard", and create module via codegen, intellisense working correctly for Razor view.
My workbench: visual studion community edition 2015 update 3.
Orchard version: 1.10.1
How i can fix this bug? Or is there another way to identify the project?
I'm looking for a way to make a project build and run as part of the build process in a solution.
Here's what I need:
First it compiles the "Generator Project", and in case of errors, it stops compiling.
Then it runs the "Generator Project", which creates some .cs files in other projects.
Then it compiles the rest of the projects.
I can see two ways of solving this.
Create and manually run the "Generator Project" when changes are made.
Construct a custom MSBuild script to do what I need.
While those two solutions work, I was hoping it might be possible to do it some easier/simpler way?
It occurs to me that you might solve your problem by using T4 Templates in the generator project (GP), then include the target .cs files generated by the templates as links into the other projects (OTP), and finally add a reference to the GP on each of the OTP so that the custom build order gets honored. I hope it makes sense.
I have an existing Node.js codebase, forked from GitHub. Now I want to import it to the Intellij IDEA 13 (ultimate version, which supports Node.js). When I simply try to import the project from the root folder of my existing code, IDEA doesn't add the 'lib' folder, where all the sources are. It should be simple, but I cannot figure it out. Any hints?
Well, I've figured out a workaround, but not sure if it's the best solution. One can just create a new project of type "Web", and point it to the directory containing the module's sources. Then IDEA understands the whole structure, and you can create run configurations with Node.js.
In order to get additional Node features, like Intellisense for standard Node APIs, you'll still want to configure the project to be a Node project:
Open the Preferences window
Click Languages & Frameworks → Node.js and NPM
In the section Coding Assistance you'll see if Node.js Core library is [not] enabled. If it is enabled, there's nothing more to do. If not click the Enable button
Leave For the whole project checked, and click Configure
The text should now change to Node.js Core library is enabled.
Another workaround:
If you have a version controlled Node app with no local changes, you could also create a new project of type "Node.js and NPM", point that to the directory. Then just use any standard settings.
After the project is created, you can just revert the files overwritten by IDEA (e.g. app.js and package.json), delete any new directories and files, and you will get the additional Node features in your project.
Intellij 15 Professional Edition:
Import a new project -> Select the base folder of the project -> choose import form existing source.
When Intellij is done it wont look correct so do the following:
1) Project Structure CMD + ;
2) Go to Modules
3) Add a new module and select Node/Npm (if you dont have it then add a new plugin)
4) Point the source of the project to the base folder and click apply.
I have a WPF class library that I want to port to be a WinRT class library. My plan is to copy the project, edit the project file so that it's a WinRT project instead of WPF, and see where I stand.
However, I cannot find which element in the project file makes it a WinRT project, and not .NET. Any ideas?
I've tried everything including diffing the project file with a WinRT class library project file, and slowly changing it over, but the WPF project never switches to WinRT in VS's eyes.
Sorry if this sounds nuts, I'm looking for the quickest way to find out how much work I need to do to port across.
Thanks
I'd take a different approach to that:
First I'd create a new Windows Store apps class library project.
Then I'd copy all the files from the existing WPF class library folder to the new Windows Store apps class library project folder (without overwriting any of existing files)
In the Solution Explorer window I'd enable Show All Files to see all the copied files and folders.
I'd multi select all the items in the treeview that belong to the project and click on Include In Project from the context menu.
At this point the only thing potentially still missing would be settings at the project level such as conditional compilation symbols and missing references which could easily be added by comparing both projects in Visual Studio or just trying to compile the new projects and seeing what goes wrong.