I am stuck with this for 2 days (mornings) now, so I venture to ask in this forum. Please bear with me, as I am still finding my way here.
I am trying to see if I can make some contributions to the nextcloud contacts app.
- I set up a developement nextcloud instance on my laptop,
- I downloaded the nexcloud contacts source from github and compiled/made it:
sudo -u www-data make (btw, is that the right way, doing everything as www-data user?)
It compiles succesfully. So I started with babysteps. First make a few silly changes to a Vue file to see if I can.
But whatever I change in /src/components/ContactDetails.vue, I can’t get it to show in the browser.
I disabled http cache, enabled debug mode in Nextcloud config.php. What am I overlooking?
I added the contacts app in the title to make it clearer.
@ChristophWurst will be glad about some help in the contacts app
Thanks. I didn’t add it, because I think this a general issue… (with my understanding of vue or nextcloud )
I hope indeed I can help a bit with contacts in the near future.
On the topic of the contacts app, In order to succesfully make it, I had to change a line in composer.json. The file phpunit.integration.xml wasn’t found. I created an issue Contact app make fails on 'Could not read "phpunit.integration.xml' · Issue #2588 · nextcloud/contacts · GitHub for this. It could of cours be that this also has something to do with my setup.
https://docs.nextcloud.com/server/latest/developer_manual/digging_deeper/npm.html might help.
npm ci once to install front-end dependencies and
npm run watch to start the process of watching files and triggering a compilation on demand.
I’ll have a look
Hi Chtristoph, all,
Short message to share that I am still pursuing this, but also that I am making very little progress.
I am able to build the app after every change. I use npm run watch and I see that it starts rebuilding every time I change a file. It breaks when I put in an error, so I am sure it is actively updating contacts based on what I do.
But I still can’t see any of the changes. I use firefox and disabled the http cache. I even downloaded chromium, to make sure 100% it isn’t something in firefox. But also there there is the pristine original contacts app. without my changes.
I will continue searching what I do wrong, but I could use some inspiration where too look:-)
Maybe I’m on to something, (or maybe it is nothing)
When I run ‘npm run watch’ It mentions it is building contacts 4.0.2.
I have no idea where this version number comes from. The version in appinfo/info.xml is 4.1.0-alpha.1?? Is this correct?
bert@trout:/var/www/nextcloud/apps/contacts$ npm run watch
> email@example.com watch
> NODE_ENV=development webpack --progress --watch --config webpack.js
Building contacts 4.0.2
Back with an other question.
I took a step back and cloned the app-tutorial app from github.
I hope that will shed some light on what I am doing wrong.
However, first of all it didn’t build and secondly it doesn’t install.
The build problem is described in 'make test' fails out-of-the-box · Issue #363 · nextcloud/app-tutorial · GitHub
The install problem in Could not download app notestutorial · Issue #6 · nextcloud/app-tutorial · GitHub
I think/hope both are fairly simple things. Could someone please take a look and help me further? CC @ChristophWurst
Small update, still scratching my head.
I build the notestutorial app. I ran into a small hickup that I needed to rename the folder to be able to install it. But after that I was able to edit notestutorial/src/App.vue, rebuild and see the resulting change directly in the browser.
Tried the same thing again in contacts and alas, nothing seems to change in the browser. It feels like I am using a completely different instance of the app than I am working on.
Any pointer is appreciated.
what versions of node/npm do you use?
Hi Christoph et. al.
Last evening I finally found out where the problem was.
When I started, and pulled the source from git, I moved the original nextcloud/apps/contacts out of the way with “mv contacs …/” So it went to the base nextcloud folder. I thought it would not do any harm there. My mistake…
I don’t know if it is a bug or a feature, but nextcloud picked up on that folder nextcloud/contacts instead of nextcloud/apps/contacts. So any changes I made in nexcloud/apps/contacts did not show up! Once I removed this nextcloud/contacts folder, my changes in nextcloud/apps/contacts became visible.
The one thing that is weird is that a version change in nextcloud/apps/contacts/appinfo did trigger an update. So apparently it did take some pieces from there as well.
Anyhow, now that I finally have a working source directory, I can start poking and seeing if I can do something useful in contacts!!