Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make the latest link relative so that the docs can be moved. #12

Merged
merged 2 commits into from
Mar 16, 2018

Conversation

allenap
Copy link
Contributor

@allenap allenap commented Mar 9, 2018

I noticed that I couldn't move the docs tree without breaking the latest links because they are absolute, e.g.

$ ls -l
total 4.0K
drwxrwxr-x 2 ubuntu ubuntu 4.0K Mar  8 16:07 1.0.0
lrwxrwxrwx 1 ubuntu ubuntu    5 Mar  9 09:55 latest -> /home/ubuntu/.../packages/rtfeltman/hex/1.0.0

This PR changes it to be relative:

$ ls -l
total 4.0K
drwxrwxr-x 2 ubuntu ubuntu 4.0K Mar  8 16:07 1.0.0
lrwxrwxrwx 1 ubuntu ubuntu    5 Mar  9 09:55 latest -> 1.0.0

@codecov-io
Copy link

codecov-io commented Mar 9, 2018

Codecov Report

Merging #12 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #12   +/-   ##
=======================================
  Coverage   97.92%   97.92%           
=======================================
  Files          11       11           
  Lines         338      338           
=======================================
  Hits          331      331           
  Misses          7        7
Impacted Files Coverage Δ
src/elm_doc/package_tasks.py 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e2e509e...37cd53e. Read the comment docs.

Copy link
Owner

@ento ento left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thanks!

assert package_dir.dirpath('latest').check(dir=True, link=True)
package_latest_link = package_dir.dirpath('latest')
assert package_latest_link.check(dir=True, link=True)
assert not os.path.isabs(package_latest_link.readlink())
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😻

@ento ento merged commit 60c9c1a into ento:master Mar 16, 2018
@allenap allenap deleted the latest-link-relative branch March 19, 2018 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants