Arc Forumnew | comments | leaders | submitlogin
Arc Repo
32 points by nex3 3098 days ago | 27 comments
It seems to me that all these patches floating around everywhere are getting confusing. It's great that people are putting so much effort into improving Arc, but it would be nice if there were a somewhat more orderly way to do it.

Thus, I've put a couple patches into a git repo and published it at git://nex-3.com/arc.git. You can browse it online at http://git.nex-3.com/?p=arc.git;a=summary.

The idea isn't to have a single standard repository, of course. It's to take advantage of the purpose of distributed revision-control systems - to provide a standard way of publishing and exchanging patches. So have at it! All you need to do is

  git clone git://nex-3.com/arc.git


6 points by nex3 3098 days ago | link

In the spirit of http://www.arclanguage.org/item?id=803, I've also created an anonymously-writable "wiki" repo at git://nex-3.com/arc-wiki.git.

  $ git clone git://nex-3.com/arc-wiki.git
  $ cd arc-wiki
  ... edit stuff ...
  $ git push

-----

1 point by greatness 3094 days ago | link

Excellent, could we get some sort of separate forum to talk about this project though to discuss bugs, recent patches, etc.. I noticed you have a module system up now, but I can't get it to work:

  arc> (impas blah spec)
  #3(tagged mac #<procedure>)
  arc> (blah:do2 nil nil nil)
  Error: "reference to undefined identifier: _blah"
And I'm not sure why it doesn't work, but I also have an Idea for a more general impas function:

  (mac impas mods 
    (do (map [apply importmodule _] (pair mods)) 
          nil))
(keep in mind this is entirely theoretical, I couldn't physically test it because the other impas didn't work.)

-----

1 point by randallsquared 3094 days ago | link

The import.arc stuff is a sketch. One of it's many shortcomings is that if you define a function blah and then use it from inside the same module/file, it won't be able to find blah, because it's been silently renamed |modulename blah| .

The problem you're having seems to be different, though.

After looking, I realize that my testing process was masking a bug where I didn't change some symbol dereference. It's fixed now on my machine, but I'm new to git, and not sure what I need to do to make it show up in the repository. I did git push, but that doesn't seem to have made it appear in the commit list.

EDIT: okay, nex3 helpfully explained things to me, so this fix is in the arc-wiki repo now. It still doesn't change use points, though, as mentioned above.

-----

1 point by randallsquared 3094 days ago | link

Replying to myself because it seems as good a place as any...

We could walk the tree of a module and patch up any symbols we find that were referenced in a def or mac, but that's not a clean solution, since it can't find all actual calls (something could be building up names, for example, which we'd never find by walking the tree).

What this means is that any module system built right now, as far as I can tell, will have to require support from those writing the modules, but since renaming modules is implicit in how import.arc works at the moment, there's no way to know what the call should look like, for the module programmer. I can't see any way around this except to change Arc itself to make function and macro definitions respect lexical boundaries, rather than all being bound at the top level. Until that change is made, all we can do is fake a module system.

-----

1 point by randallsquared 3094 days ago | link

My own thought was that we'd have an

    (impfrom modulename name1 name2 ...) 
such that only those names would be imported, like Python's

    from modulename import name1
and that then impas would be extended to take given names as well, like

    (impas newname modulename name1 name2 ...)
However, I don't feel strongly about it either way.

-----

1 point by nex3 3094 days ago | link

I think this forum is as good as any for now.

-----

2 points by bootload 3098 days ago | link

"... The idea isn't to have a single standard repository, of course. It's to take advantage of the purpose of distributed revision-control systems - to provide a standard way of publishing and exchanging patches. ..."

Hey nex3 that is such a neat solution, using git is smart.

-----

2 points by akkartik 3097 days ago | link

The svn and git are actually separate wiki repos, right? Do patches flow between them?

-----

2 points by nex3 3097 days ago | link

They are separate repos, but I have a git-svn mirror on my local machine from which I've been periodically pulling in any changes to the Subversion wiki and push them to the git wiki. Anyone else is, of course, welcome to do the same.

-----

2 points by akkartik 3097 days ago | link

Cool, so patches flow one way and could in principle flow both ways.

Hold on though, will this scale, or will the cost of merging patches from svn become prohibitive? People would in principle be pushing on both the git and svn sides.

-----

2 points by nex3 3097 days ago | link

Patches are currently flowing both ways as people commit to both repositories.

Git has excellent merging tools, including a way to step through the history of both the Subversion and Git sides, applying patches automatically when possible and asking the user for manual assistance when there's an ambiguity. Even if the repositories get horribly out-of-sync, which I'll try to make sure they won't, it'll only take a moderate amount of effort to get them back to a stable state.

-----

3 points by ambition 3094 days ago | link

I put a note in the subversion repository to this effect --- unless there are any complaints, I'm going to take the code out of the SVN repository and leave only a note. There's no point in spending any time merging back and forth.

For now, anyone who is interested in Arc is smart enough to figure out git.

-----

1 point by pau 3098 days ago | link

Also excellent! I'm following it through RSS...

-----

1 point by akkartik 3097 days ago | link

Whoa, how'd ya do that?

-----

3 points by nex3 3097 days ago | link

http://git.nex-3.com/?p=arc-wiki.git;a=summary has both Atom and RSS feeds.

-----

1 point by akkartik 3097 days ago | link

Oh, so in general there's a mapping from git://hostname to git.hostname? I didn't know that.

-----

2 points by nex3 3097 days ago | link

I'm not sure how general it is... just how I chose to set up my server.

Edit: Speaking of nice URLs, you can now get at the browser through http://git.nex-3.com/arc-wiki.git.

-----

2 points by randallsquared 3094 days ago | link

Okay, can someone point me at a good tutorial that talks about how we're supposed to commit with git push?

No matter what I do, I can't seem to clear the warnings given by git status:

I've tried the helpfully suggested lines it mentions:

    git reset HEAD import.arc
    git reset HEAD lib/import.arc
    git rm import.arc
    git add lib/import.arc
and git push at various times, and I can't seem to get it to stop warning me about things I need to do, and no matter how many times I git push, nothing seems to change on the web summary. Is there some equivalent of the basic 'svn commit -m "comment" ' that does the trick?

-----

8 points by nex3 3094 days ago | link

Git makes a distinction between your local repository and remote repositories. You have to commit your change to your local repo before you can push it to the remote one. So first you "git commit," then you "git push."

The total workflow goes something like this:

  git clone git://nex-3.com/arc-wiki.git
  emacs lib/import.arc   # Make your edits
  git add lib/import.arc # Schedule lib/import.arc for committing
  git commit             # Commit lib/import.arc to your local repo
  git push               # Push your local changes to the remote repo
The "git add" step is due to a little idiosyncrasy of Git where "commit" doesn't commit any changes you don't explicitly tell it to via "git add." You can also do "git commit -a" to automatically add all changes before you commit.

Also, "git commit" takes the same -m parameter that "svn commit" does.

Finally, the GNU Smalltalk folks have a good intro to Git: http://smalltalk.gnu.org/blog/bonzinip/using-git-without-fee....

-----

1 point by randallsquared 3094 days ago | link

Thank you; that was exactly what I needed. :)

-----

1 point by treeform 3073 days ago | link

i hope pg commits to it too

-----

3 points by pau 3098 days ago | link

Excellent! I was about to do this myself... I also saw the SVN put by ambition, but git is just nicer... ;)

-----

2 points by CatDancer 3095 days ago | link

Thank you! I was just starting to see if I could fix date on my Linux system when I thought, "hmm... I should go see if someone has fixed this already..." and there it was in your git repository! A fix by Nathan Weizenbaum! Yay!

-----

1 point by randallsquared 3093 days ago | link

So, what's going on with all these "Revert", "Revert 'Revert'", etc?

-----

2 points by wfarr 3097 days ago | link

Rock on nex3!

-----

0 points by synjones 2874 days ago | link

I have gone through this but i was not able to understand can i have some more information on this.

synjones [url=http://www.gov-auctions.org] Auto Auctions [/url]

-----

0 points by synjones 2874 days ago | link

I have gone through this but i was not able to understand can i have some more information on this.

synjones [url="http://www.gov-auctions.org"]Auto Auctions [/url]

-----