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

README.rst, NEWS.rst, CONTRIB.rst, DEPRECATED.rst etc #1067

Merged
merged 17 commits into from Mar 1, 2017

Conversation

peterjc
Copy link
Member

@peterjc peterjc commented Feb 23, 2017

Renames our legacy extension-less text files to use *.rst and tweak their contents as needed to render nicely as reStructuredText which looks much nicer under GitHub etc.

Creates symlinks in order to preserve the legacy filenames (although I'm not sure how important that is?).

See also http://mailman.open-bio.org/pipermail/biopython/2017-February/016083.html and http://mailman.open-bio.org/pipermail/biopython-dev/2017-February/021644.html

Pending an enhancement of rst-lint from https://github.com/twolfson/restructuredtext-lint/ to allow it to ignore "info" level issues, I plan to add checking the markup to our TravisCI setup.

CONTRIBUTING is new, so not adding that here.
Automated using:

$ cat NEWS | python bullet_names.py > NEWS2 && mv NEWS2 NEWS.rst

where the script was a simple state-machine:

import sys
status = 0
for line in sys.stdin:
    if status == 0:
        if line.rstrip().endswith((" contributors:", " contributors since the beta:", " people:", " first timers:")):
            status = 1
    elif status == 1:
        if line.strip():
            status = 2
            line = "- " + line
    elif status == 2:
        if not line.strip():
            status = 0
        else:
            line = "- " + line
    sys.stdout.write(line)
Note still have a warning present from rst-lint from Bio.sequtils
vs Bio.SeqUtils, which is legitimate:

$ rst-lint DEPRECATED
INFO DEPRECATED:591 Duplicate implicit target name: bio.sequtils.
Automated using:

    $  python retitle.py < NEWS.rst > NEWS2 && mv NEWS2 NEWS.rst

where this was a simple state-based script:

import sys
status = 0
for line in sys.stdin:
    if status == 0:
        if line.rstrip() == "===================================================================":
            line = ""
            # sys.stderr.write("Found break\n")
            status = 1
    elif status == 1:
        assert not line.strip()
        status = 2
        # sys.stderr.write("Found blank line after break\n")
    elif status == 2:
        if line.strip():
            # sys.stderr.write("Found title: " + line)
            line += ("=" * len(line.strip())) + "\n"
            status = 0
    sys.stdout.write(line)
@peterjc
Copy link
Member Author

peterjc commented Feb 23, 2017

Note this does not introduce back-ticks everywhere, e.g. Bio.SeqIO, which would be a nice further step in future.

It has also made me even more aware that there is no clear ordering convention in the DEPRECATED file, which might be worth addressing at a later date.

@codecov-io
Copy link

codecov-io commented Feb 23, 2017

Codecov Report

Merging #1067 into master will decrease coverage by -0.02%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #1067      +/-   ##
==========================================
- Coverage   80.68%   80.67%   -0.02%     
==========================================
  Files         323      323              
  Lines       49853    49853              
==========================================
- Hits        40224    40218       -6     
- Misses       9629     9635       +6
Impacted Files Coverage Δ
Bio/GA/Evolver.py 54.54% <0%> (-18.19%)
Bio/NeuralNetwork/Gene/Schema.py 71.07% <0%> (-0.83%)

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 79ed27c...d14aa0d. Read the comment docs.

@cbrueffer
Copy link
Member

Looks fine to me!

@peterjc
Copy link
Member Author

peterjc commented Mar 1, 2017

Given no objections and one endorsement, applying now...

@peterjc peterjc merged commit 970613d into biopython:master Mar 1, 2017
@peterjc peterjc deleted the use_rst branch March 1, 2017 10:26
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