{"id":13337086,"url":"https://gitlab.com/ddnet-rs/twmap-py","last_synced_at":"2025-03-11T04:31:28.495Z","repository":{"id":59268427,"uuid":"29019762","full_name":"ddnet-rs/twmap-py","owner":"ddnet-rs","description":"Python bindings for the crate twmap","archived":false,"fork":false,"pushed_at":null,"size":null,"stargazers_count":2,"open_issues_count":2,"forks_count":3,"subscribers_count":null,"default_branch":"master","last_synced_at":"2025-03-04T17:04:18.549Z","etag":null,"topics":["DDNet","teeworlds"],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":null,"metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-08-21T09:33:05.573Z","updated_at":"2025-01-21T00:20:37.890Z","dependencies_parsed_at":"2022-09-21T22:04:21.266Z","dependency_job_id":null,"html_url":"https://gitlab.com/ddnet-rs/twmap-py","commit_stats":null,"previous_names":["patiga/twmap-py"],"tags_count":2,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories/ddnet-rs%2Ftwmap-py","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories/ddnet-rs%2Ftwmap-py/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories/ddnet-rs%2Ftwmap-py/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories/ddnet-rs%2Ftwmap-py/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/owners/ddnet-rs","download_url":"https://gitlab.com/ddnet-rs/twmap-py/-/archive/master/twmap-py-master.zip","host":{"name":"gitlab.com","url":"https://gitlab.com","kind":"gitlab","repositories_count":4518022,"owners_count":6813,"icon_url":"https://github.com/gitlab.png","version":null,"created_at":"2022-05-30T11:31:42.605Z","updated_at":"2024-07-18T11:24:13.055Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/owners"}},"keywords":["DDNet","teeworlds"],"created_at":"2024-07-29T19:11:13.053Z","updated_at":"2025-03-11T04:31:27.643Z","avatar_url":null,"language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"TwMap Python Module\n===\n\nSafely parse, edit and save [Teeworlds](https://www.teeworlds.com/) and [DDNet](https://ddnet.org/) maps - in Python!\n\nSee the Rust library [twmap](https://gitlab.com/Patiga/twmap) for details on the wrapped library.\n\nInstallation\n---\n\nSimply do `pip install twmap`!\n\nUsage\n---\n\nThe `help` function is your friend!\nOnce you imported `twmap`, do `help(twmap.Map)` to access the documentation of the `Map` struct.\nIt also contains important general knowledge about the module.\n\nTo load your first map, do `map = twmap.Map(path-to-map)`.\nTo see the attributes and documentation about an object... `help` helps you!\n\nFor example, have a look into `help(map.groups)` and `help(map.groups[0])`.\nThe first one will give you methods on the group collection and the second one attributes and methods on group objects.\nIf you are confused about something in the module, the general information in `help(twmap.Map)` might help you.\n\nManual Building (on Linux)\n---\n\nYou need [Rust](https://www.rust-lang.org/tools/install) installed on your system.\nTo compile twmap in release mode, execute the following command in the source root:\n```\ncargo build --release\n```\nLocate the file `target/release/libtwmap.so`.\nThis file is only importable under `twmap.so`.\nSymlink or copy it to your desired location.\n\nPublishing Steps\n---\n\nThese steps are the ones I use to upload new versions of twmap-py to [pypi](https://pypi.org/).\n\n**Linux**:\n\n1. `podman pull ghcr.io/pyo3/maturin`\n2. `podman run --env \"MATURIN_PYPI_TOKEN=\u003ctoken\u003e\" --rm -v $(pwd):/io ghcr.io/pyo3/maturin publish -f`\n\n**Cross-compiling to Windows**:\n\n1. Download the newest version of the oldest non-end-of-life Python edition \"Windows x86-64 embeddable zip file\" from https://www.python.org/downloads/windows/. Last used: https://www.python.org/ftp/python/3.8.2/python-3.8.2-embed-amd64.zip\n2. Unzip in project root\n3. `MATURIN_PYPI_TOKEN='\u003ctoken\u003e' RUSTFLAGS='-C target-feature=+crt-static' PYO3_CROSS_LIB_DIR='./\u003cpath-to-unzipped-python\u003e' maturin publish --target x86_64-pc-windows-gnu` (replace the directory path)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/gitlab.com%2Fddnet-rs%2Ftwmap-py","html_url":"https://awesome.ecosyste.ms/projects/gitlab.com%2Fddnet-rs%2Ftwmap-py","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/gitlab.com%2Fddnet-rs%2Ftwmap-py/lists"}