• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Gallopsled / pwntools / 11306567235

12 Oct 2024 02:57PM UTC coverage: 74.25%. First build
11306567235

Pull #2486

github

web-flow
Merge b9c0426e6 into 78dd77773
Pull Request #2486: Test Python version >= 3.10 in CI and fix tests on Python 3.12

3679 of 6140 branches covered (59.92%)

20 of 34 new or added lines in 22 files covered. (58.82%)

12973 of 17472 relevant lines covered (74.25%)

0.74 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

57.89
/pwnlib/commandline/version.py
1
#!/usr/bin/env python
2
from __future__ import absolute_import
1✔
3
from __future__ import division
1✔
4

5
import os
1✔
6
import subprocess
1✔
7

8
import pwnlib.args
1✔
9
pwnlib.args.free_form = False
1✔
10

11
from pwn import *
1✔
12
from pwnlib.commandline import common
1✔
13

14
parser = common.parser_commands.add_parser(
1✔
15
    'version',
16
    help = 'Pwntools version',
17
    description = 'Pwntools version'
18
)
19

20
def main(a):
1✔
21
        version = pwnlib.version
×
22

23
        git_root = os.path.dirname(os.path.dirname(os.path.dirname(__file__)))
×
24
        if os.path.exists(os.path.join(git_root, '.git')):
×
25
                gitver = subprocess.check_output(['git', '-C', git_root, 'log', '-1', '--format=%h (%cr)'])
×
26
                branch = subprocess.check_output(['git', '-C', git_root, 'rev-parse', '--abbrev-ref', 'HEAD'])
×
27
                version = '%s-%s-%s' % (version, branch.decode().strip(), gitver.decode())
×
28

29
        log.info("Pwntools v%s" % version)
×
30

31
if __name__ == '__main__':
1!
NEW
32
    pwnlib.commandline.common.main(__file__, main)
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc