Existing htaccess overwritten on upload

Just tried this with Wappler 1.9.0
My existing .htaccess file was overwritten on publishing. @George, can you please check?

Hello,
Have you first downloaded your .htaccess file locally?

Nope. Will try that out.

Well Wappler just adjusts the found htaccess locally so always make sure you have your existing htaccess downloaded first

Thank worked. :+1:
@Teodor You should add this to the tutorial doc - maybe in the NOTES section at the end.

2 Likes

Added :slight_smile: Hope it makes things more clear now.

1 Like

I’m just setting up a new Mac at home and have pulled my work from github and all is good apart from the routing. I have downloaded the .htaccess file so the routes are there but the Routing part of Wappler isn’t showing any. I am concerned that adding another route will overwrite the existing ones.

Should the Routing tab read the details from the .htaccess file or is there another file I should be copying? If there’s another file, shouldn’t it be in my github repo?

Hello @sitestreet,
You should also sync/get the .wappler folder located in your project root folder.

Thanks @Teodor. That file doesn’t seem to contain any routing info for some reason.

Which file are you referring to exactly?

Aah, I think I see the issue. There’s a routes.json file which isn’t being pushed to github. I only see project.json in my repo.

Any idea why the Git manager isn’t picking up that file? Is there an exclusion somewhere?

There’s a .gitignore file which contains this:

.wappler
node_modules

So I’m guessing this is why. Is it safe to just remove the .wappler line from that?

I’ve gone ahead and removed the first line from the .gitignore file and pushed it and it’s now in my repo.

Is there a reason why this would be a bad idea? I can’t see anything in any files which directly relate to local settings like file paths.