>From the output you showed, you seem to have only replaced the "rackunit"
package, which is just a stub to depend on the "rackunit-lib",
"rackunit-doc", "rackunit-gui," and "rackunit-plugin-lib",  packages—those
you still have installed in the installation default place. It also looks
like you may have installed the root of the git repository as the package:
the repository's subdirectories are the individual packages.

There is documentation at https://docs.racket-lang.org/pkg/git-workflow.html
and this blog post:
https://blog.racket-lang.org/2017/09/tutorial-contributing-to-racket.html
The easiest way is to run:

raco pkg update --lookup --catalog https://pkgs.racket-lang.org --clone
rackunit

This will even take care of cloning the Git repository for you; however, it
will set up https://github.com/racket/rackunit as the repository's origin.
Personally, I prefer to have my fork as origin and the official repository
as upstream. You can change this after cloning, but I prefer to clone the
repository over ssh as usual: if you do that, raco will leave your git
settings alone.

The step where I most often get confused is remembering the correct
incantations to link an existing Git checkout of a package from a
repository like rackunit with multiple packages, since raco tries to infer
the directory from the name of the package, but wants to be given the
repository root as the destination directory. (It will ask to also link
other packages that share the same repository, which you should do.) I've
just tried this to be sure, and you can give the path to the repository
root explicitly like this:

raco pkg update --lookup --catalog https://pkgs.racket-lang.org --clone .
rackunit

-Philip

On Fri, Apr 5, 2019 at 7:16 PM Alex Harsanyi <alexharsa...@gmail.com> wrote:

> Here are some notes that I wrote to deal with this situation, except they
> use the plot package:
>
>
> https://alex-hhh.github.io/2018/01/changing-built-in-racket-packages.html
>
> You will also find some more information about this topic if you search
> this group, but most of what is explained in those posts seems to be for
> cases where raco can modify the main Racket installation and it does not
> work if the racket is installed at system level and you run raco as a user
> only.
>
> OTOH, my process does not seem to work with "raco setup" commands for the
> cloned package, so you will than have to manually run "raco make" to
> compile your changes and run scribble to generate the documentation.  Maybe
> I just have to pass some special arguments to "raco setup" but I have not
> found what those are (but did I look very hard :-) )
>
> Alex.
>
> On Saturday, April 6, 2019 at 4:03:06 AM UTC+8, zeRusski wrote:
>>
>> I thought about hacking on /rackunit/ a bit and if it pans out maybe send
>> my changes upstream. Typically I would clone a repo and then do raco pkg
>> install in its folder so that I have it linked and code that may require it
>> picks up latest changes. Very convenient workflow. Except /rackunit/ is
>> special (no surprise there) it comes pre-installed and in the installation
>> scope and basically other things depend on it, so don't touch it says
>> /raco/. Here's what I tried next:
>>
>> cd to rackunit parent dir and
>>
>> raco pkg update -i --force --type dir ./rackunit/
>>
>>
>> but I don't see the "Linking directory ..." message there. Is it copying
>> stuff? See, not only do I want my changes picked up automatically by other
>> code, I also want to be able to jump to definition and arrive at that local
>> repo. And its a good litmus test for whether I'm actually linking or moving
>> stuff to collects somewhere.
>>
>> Trying nuclear (but, really, I have no clue what I'm doing here):
>>
>> ~/Code/rackunit $ raco pkg remove --force rackunit
>>> ~/Code/rackunit $ raco pkg install --force
>>> Linking current directory as a package
>>> raco setup: version: 7.2.0.12
>>
>>
>> Looks good. Also I think I installed it as in -user scope. Except, nope.
>> Jump to definition still takes me to some
>> share racket-7.2.0.12/share/pkgs/rackunit-lib/rackunit/private.
>>
>> Same goes for changing code in locally cloned repo. Changes aren't picked
>> up. Is /rackunit/ special somehow? Or is there some weird PATH that's
>> shadowing linked /rackunit/? Should I nuke dirs that mention /rackunit/
>> inside racket-7.2.0.12/share/
>>
>> Thanks
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to