#1GB for a starter (almost) empty project?

37 messages · Page 1 of 1 (latest)

undone drift
#

This is a release build for my project. I used NextJS

#

Just created the project. Havent done anything

arctic gate
#

this folder have source code of all required dependencies used to build it, it will have node_modules (biggest I guess) and target folder with bunch of incremental builds to improve speed

#

node/js project are famous for it

#

don't worry your final release version of app will have only required code

undone drift
undone drift
#

I just run tauri build

#

The obsidian app (I think also made with tauri) is only 200mb

#

Or is there any extra junk left after that command?

#

intermediate files perhaps?

arctic gate
#

are you looking into src-tauri/target/release/bundle ??

#

my fresh react and tailwind is only 3.8 mb, only appimage is 136 MB (it is suppose to be large)

#

1 GB is still very large, but that is not bundle. I have 12 mb file for this project in release folder. may be your frontend is including some binaries from node packages. you have to optimize that may change some dependencies to devDependencies

lilac forum
#

The screenshot shows 3k files and 551 folders, no way this is the final artifact. This is the target folder with all rust deps and other bundle files.

#

Also 200mb for a final app on windows sounds completely unrealistic if you do not bundle like ~185 mb and/or have the offline webview2 installer bundled.

undone drift
undone drift
undone drift
lilac forum
# undone drift I think this might be it. How do I know which files I don't need?

You need these files during build, so a development folder containing ~10gb of intermediate files, build files etc is not unusual. You only need the .exe/.msi to run your tauri app. So in your case I assume you have an <yourapp>.msi file in your target folder right? This is the only file needed to install and run the tauri app on your or other windows systems.

#

to test things locally on your machine the <yourapp>.exe can be used

arctic gate
# undone drift I think this might be it. How do I know which files I don't need?

src-tauri/target/release/bundle/***/ you only need to share setup file from this folder, rest of files are reused by tauri, you don't need to save any file form target folder they are safe to delete but never need to delete them as they will be recreated on every build. target folder is in .gitignore so it stay on your disk to be re used only. you can delete entire target folder. but only delete it if you try to save code in rar/zip or you need disk space when you are not working on project for long time. deleting it create more work for tauri and slow new build process.

devout wagon
#

something like this

undone drift
#

Thank you everyone who has explained everything so patiently😭 will try everything as soon as I got home

arctic gate
#

bundle folder have multiple folder based on OS you are building on and target OS for you are building. I am on linux so I have these folder but on window you will have windows related. in window folder you have your setup file. as @devout wagon said final release setup file that you can send to your user will be listed at the end with message " Finished * bundles at:"

#

I typed half message last night, got too sleepy and forgot to send 😦

undone drift
#

Ohh yea it's just 2mb 😭

#

Thank you guys!

#

Can I just share the exe itself though as a single executable?

arctic gate
#

install it and test to see if everything work as expected, then congratulations you are a Desktop app developer, update resume then yes you can send it to friend with new resume.

lilac forum
undone drift