Skip to content
This repository has been archived by the owner on May 2, 2020. It is now read-only.

relpath is only needed for julia < 0.4- #74

Closed

Conversation

peter1000
Copy link
Contributor

relpath got merged: JuliaLang/julia#10893

@MichaelHatherly
Copy link
Owner

Since relpath isn't available in every version of 0.4- you'll need to make that conditional more specific, such as 0.4-XXXX where XXXX can be calculated using the script in the Compat package, https://github.com/JuliaLang/Compat.jl#developer-tips. (Technically the findprev and findlast should be as well. I can get that sorted since it was me who suggested using the conditional.)

Perhaps we should move all the "compat"-like things into a separate file, compat.jl, to better keep track of compat fixes specific to this package?

@peter1000
Copy link
Contributor Author

Perhaps we should move all the "compat"-like things into a separate file, compat.jl, to better keep track of compat fixes specific to this package?

Ok I can start this and resend here a PR?

@MichaelHatherly
Copy link
Owner

Ok I can start this and resend here a PR?

Yeah, that's fine.

@MichaelHatherly
Copy link
Owner

I'm getting:

$ compat.sh e3aa57efbc6542efbcc7feac9b1309d628ac6f12
2418

for the find methods and

$ compat.sh 13302e6dd94b188d6a09ec35f7f0291e77ee3686
4393

for your relpath addition.

@peter1000
Copy link
Contributor Author

just for the future: could you show me shortly the whole process how to get the number - never did it?

from where is the compat.sh?

@MichaelHatherly
Copy link
Owner

Put the bash script found at the bottom of the Compat README into a file

#! /bin/bash
last_tag=$(git describe --tags --abbrev=0)
git rev-list $1 ^$last_tag | wc -l | sed -e 's/[^[:digit:]]//g'

on your path and make it executable using chmod +x compat.sh. (This assumes you're on a *nix system, can't help you if it's windows, appologies.)

Search the git commit logs for the specific commit that added the feature. Best to just use the github interface for this I find. This was yours JuliaLang/julia@13302e6.

Get the hash associated with the commit. (13302e6dd94b188d6a09ec35f7f0291e77ee3686).

cd into the julia repo.

Run

$ compat.sh 13302e6dd94b188d6a09ec35f7f0291e77ee3686

and use the resulting XXXX number in the conditional.

if VERSION >= v"0.4-XXXX"
    # ...
end

@peter1000
Copy link
Contributor Author

Thanks

@peter1000
Copy link
Contributor Author

sorry forgot to push here - a new PR #76

@peter1000 peter1000 closed this Apr 22, 2015
@peter1000 peter1000 deleted the relpath_only_for_julia_0_3 branch April 23, 2015 13:25
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants