Editing news.arc won't "reload" your changes. If you write the code to the file, it won't actually execute that code. Does that make sense?
You want to go back to the arc> prompt (where you started (nsv)) and do something to get that code to run. You could do this in a few ways. You could do:
arc> (load "news.arc")
which will reload the changes you saved to the news.arc file. It might look crazy, because it prints out a bunch of messages that look like
*** redefining logins-page
It'll do that because it's reloading the entirety (!) of news.arc, which includes a bunch of other code. Thus, there are warnings about "redefining" certain code. But as long as you didn't actually change the code in question, it should be fine.
At the end of the day, this is probably the best way to go, despite all the intimidating warning messages. Because if you edit the news.arc file, then the changes you make will be saved in case you ever need to restart the forum in the future.
But, for the sake of completeness, I'll explain how you can also just edit the variables by hand at the prompt. So, instead of changing news.arc to say
(= this-site* "Match Fixing Scandals"
site-url* "http://news.yourdomain.com/"
parent-url* "http://www.yourdomain.com"
favicon-url* ""
site-desc* "What this site is about." ; for rss feed
site-color* (color 180 180 180)
border-color* (color 180 180 180)
prefer-url* t)
and reloading news.arc, you could actually just put the entire thing above (called an expression) into the arc> prompt:
arc> (= this-site* "Match Fixing Scandals"
site-url* "http://news.yourdomain.com/"
parent-url* "http://www.yourdomain.com"
favicon-url* ""
site-desc* "What this site is about." ; for rss feed
site-color* (color 180 180 180)
border-color* (color 180 180 180)
prefer-url* t)
This will execute the code, thus modifying your settings.
You could also use simpler expressions---or, really, any Arc code you want. If you weren't a coder before, you are one now! :)
The expression above of the form (= a b c d ...) can be used to change the values of any number of variables (setting a to b, c to d, etc.), which will control how the site displays. So, you could do something like
One of these settings you'll want to change is buried deep inside of news.arc (about 400 lines down), so it's hard to spot. But, you can change these variables, too:
I tried to put the entire expression into the arc> prompt and also tried to use simpler expressions, but I still can't get "My Forum" to change.
I've also reloaded news.arc several times and I'm not sure if it means anything, but when I go back to the arc> prompt and enter
arc> (load "news.arc")
I get
nil
and only after loading news.arc a second time I get the
"* redefining" messages
I remember that to run news.arc the first time I also used (nsv) so I tried that as well and for what is worth I got the following error:
rm: cannot remove ‘arc/news/story/*.tmp’: No such file or directory
load items:
user break
context...:
/home/ubuntu/arc/ac.scm:1031:20
gs1259
user break
context...:
/home/ubuntu/arc/ac.scm:1031:20
gs1259
Error: "tcp-listen: listen failed\n port number: 8080\n system error: Address already in use; errno=98"
arc>
Hmmm it's been a really long time since I looked at the code, but I would try two things.
1. Enter this-site* at the prompt to confirm the change took place.
2. Abort the session, I.e such that the arc prompt is killed. Then goto the webpage and make sure its no longer running news (just to confirm the abort occurred and/or is not somehow running a past instance), then reload arc again.
Yeah these are good suggestions. The "address already in use" error suggests that you might have multiple copies of arc running, so that you're making changes to the wrong copy. Use the commands 'ps' and 'kill' to look for the other copies and stop them.
I used the command
ps aux | grep 'news.arc'
and it returned only one copy running, but I suspect that's not right.
And your comment about multiple copies also got me thinking that from the main Arc directory to go into the Arc prompt maybe I shouldn't have been using
$ mzscheme -f as.scm
Was I supposed to use that just once to run news.arc for the first time?
Assuming you're using 'GNU screen' you also have the option to re-attach to an existing session using the 'screen -r' command. Using 'screen -ls' will list out all the sessions should you not be sure, or have more than one.
That aside, most developers will do development changes on a local machine where they need not attach/reattach and this way you wouldn't need to troubleshoot your code and the host environment at the same time.
Then you create a stable deployment process. eg. Backup the old code, drop in the new code, re-attach to the existing session and either load your changes or restart the program if you're ok with some nominal downtime.
No problemo and yeah, in retrospect, I could have chosen better terminology and been much more descriptive, but that's one of the things you will enjoy about the arc forum... You just keep asking and, generally speaking, people are very helpful. After all, I learned how to program by just doing what you are, running the news app, reading the arc code and relying on this forum for help along the way.