Closed DorimeDoge closed 3 years ago
Does this wiki page help maybe? https://github.com/eikek/sharry/wiki/Translation Or do you have some specific problems? How to install sbt/elm etc can be found on their page. Usually it is either apt-get install or npm install
Here is another page with some instructions (in case you didn't see it): https://eikek.github.io/sharry/doc/dev#building
Hello again,
I installed Sbt with help of this tutorial (https://www.scala-sbt.org/1.x/docs/Installing-sbt-on-Linux.html) and Elm with this one (https://github.com/elm/compiler/blob/master/installers/linux/README.md).
Did I get it right?
And should I compile it by make or by make-zip? Whats the difference?
Thanks
Yes, this looks good! you can check via elm --version
and sbt -h
.
If you want to build the zip files, then run sbt make-zip
- I guess that's what you want. The make
builds the whole application, but doesn't package it up into a zip file.
Edit: You also need nodejs installed for the current version. It's again apt-get install nodejs or similiar (don't use ubuntu myself).
Hello again,
Thanks for help! You said you can install Elm via npm, is it better to install it like this or in my way?
Thanks
Ah no, whatever the elm site says, is right! I think you can now just download the binary from somewhere and the npm package did just this before. So it doesn't really matter in the end. If you can run elm
then it's all fine.
Hello,
Alright thanks!
Hello again :D,
And how do I need to compile? Go to directory where all source is, run stb and then stb make-zip?
What do you want to do? Maybe I can give better help then :-).
The make
will compile the app. The make-zip
runs first make
under the hood and then creates a zip file. So compilation happens on both commands. If you only want to compile, then make
is better.
At first, go into the source root and just sbt
. Then you get another shell, there you can type make
or make-zip
.
Hello,
What I want to do is to compile .zip file for usage like in releases.
Thanks
Ah ok, then you can just run sbt make-zip
from your terminal inside the source root. The zip file is then in modules/restserver/target/universal/
.
Hello,
I got these errors trying to compile with sbt make-zip. Please help.
Thanks
Oh, I think I told you wrong :( - the make-zip
doesn't call make
before. You need to run make
yourself. Try sbt ";make; make-zip"
(from your terminal) This runs these two commands in a row.
Hello,
So as I understand I have to do:
cd /home/sharry sbt make sbt make-zip
Or
sbt ";make; make-zip"
Am I right?
Thanks
Yes, right - this should work. The second form is a bit faster, because sbt doesn't need to start twice.
Hello,
I tried sbt ";make; make-zip" and it still gave me same error:
Then it compiled something else and at the end it said "Killed".
I tried to find .rar file in /home/sharry/modules/restserver/target/ and there is no /universal/
Please help, Thanks
Ah these two npm warnings are not a problem I think. Are there other errors?
It's not a "rar" file, you need to look for a zip file.
Hello,
Sorry, yes .zip file, but I dont even find /home/sharry/modules/restserver/target/universal/
Question: What OS do you use to build Sharry?
Thanks
Can you find /home/sharry/modules/restserver/target/ ? Can you maybe pipe all the output into a file and send it to me?
Hello,
Yes I can find /home/sharry/modules/restserver/target/, but I cant find /universal folder.
Thanks
Ok, could you run this command like this
sbt ";make ;make-zip" 2>&1 > logfile.txt
and send me the logfile.txt
file? Maybe via pastbin.com or someting like that or email?
Thanks! Well, it looks a bit strange. Is nothing being output after this line
[info] compiling 20 Scala sources to /home/sharry/modules/common/target/scala-2.13/classes
(this is the last line in your logs) I don't see any error :-)
Could you try to raise the memory: sbt -mem 2048 "make ;make-zip"
. What system are your running this on (uname -a
)?
Hello,
I tried sbt -mem 2048 "make ;make-zip"
and got this error.
For uname -a
I got 4.15.0-144-generic #148-Ubuntu SMP Sat May 8 02:33:43 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
.
Thanks
Inetresting. Your machine has <1G RAM? This could be problematic. You can try to give a little more to the build but not so much :-) try -mem 780
or something like that.
Hello again,
Yes, its shitty VPS just to test Sharry, I can host Sharry but I cant compile it. :(
I tried everything you said but I just cant. It says like Compiled succesfully, then [info] compiling 20 Scala sources and etc., but kill everything of nowhere. ;(
I even tried it on not bad Windows 10 computer, same error.
Can you try to compile it by yourself to see if everything really works, please? :\
Thanks
Yes, it works. You can see the ci where it compiles and tests each change, for example: https://github.com/eikek/sharry/runs/3058770641. What you can do is fork sharry and add your own github action that compiles it etc. Or if you have a laptop lying around, this should also work.
Hello,
Oh, but what OS you are using and what Java and JDK, Nodejs versions are you using?
Thanks
I'm using NixOS (GNU/Linux on x86_64), OpenJDK 11 and NodeJS 14.17.0. The CI runs on Ubuntu (don't know what exact version, guess its 20.04).
Hello,
Should I try to install NixOS on my VPS and try to compile then?
Thanks
no, I think this won't help. I think it's too less memory etc. It builds on all Linuxes where the required tools are installed
Hello
Oh, and whats your specs?
Thanks
You don't have any other computer to build on? I don't know the minimum specs. Here on my physical machine, it runs with 400M memory (via sbt -mem 400m). It seems that the process is killed on your vps, but I don't know why. I would use another computer to build on, either the VMs from github actions (or another ci) or just use your desktop?
Hello,
As I said I already tried it on my Windows 10 computer, same error as I remember but I will check :/
Thanks
Ah sorry, forgot that :-). It might not build easily on windows (I never tried, I have no windows). But you can install virtualbox on your windows machine and create a VM there with Ubuntu. Then you can control how much memory/cpu etc it gets. I think this would work then. Alternatively you could try docker - not sure how/if that works on windows, though.
Tried with 400mem and got errors :(
What errors and where - on windows? If they are different, then you could paste it here
Maybe you have Discord? If yes could you give me it?
Unfortunately not … I use matrix?
Hello,
Oh, never mind then.
Thanks
Hello,
What are requirements to compile source? Like NodeJS, JDK, etc.
Thanks
Sharry uses tailwindcss, which requires Node.js 12.13.0 or higher (I'm using 14.17.0). Java must be at least 8 to compile and run. Elm must be 0.19.1. If you install sbt, which is required when building sharry, then Java comes as a dependency and is available automatically on most systems.
Hello again,
I tried it on VirtualBox and it works! :D
Thanks
And I want to ask, do you get same error as I do?
Yes, I also see this. I'm not so sure why. I think there is some npm dependency that only runs on darwin (osx); since its optional it prints as a warning. And everything that is printed to stderr from the npm process is marked by sbt as [error]
but npm says its WARN, so it's not a problem. From the name, fsevent could be a dev dependency for watching files - but just a guess. npm is only used to build the minimized CSS file that gets included in the application. The application itself doesn't use any npm stuff.
Hello again,
Thank you so much for everything, have a good day!
Hello,
Could I get step by step guide how to compile source code with steps how to install Elm & Sbt for Ubuntu 18.04?
Thanks