Skip to main content

A Python library to run Swift code

Project description

swiftonpython là một thư viện Python giúp thực thi mã Swift từ Python, tích hợp linh hoạt để bạn có thể chạy mã Swift mà không cần biên dịch .so riêng biệt. Chỉ cần cài đặt và sử dụng ngay trong dự án Python.

Cài Đặt: Đảm bảo rằng bạn đã cài đặt Swift và có thể truy cập từ dòng lệnh.

Cài đặt thư viện từ PyPI:
Link github: https://github.com/hqmdokkai/swiftonpython.git

pip install swiftonpython

Sử Dụng: Sau khi cài đặt, bạn chỉ cần import thư viện và thực thi mã Swift trực tiếp từ Python.

Ví dụ sử dụng:

import swiftonpython

# Mã Swift bạn muốn chạy
swift_code = """
print("Hello from Swift!")
"""
# Gọi hàm để thực thi mã Swift
swiftonpython.swiftonpython(swift_code)

Vậy là xong! Mã Swift sẽ được thực thi trực tiếp trong môi trường Python mà không cần phải cấu hình phức tạp.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

swiftonpython-0.3.tar.gz (2.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

swiftonpython-0.3-py3-none-any.whl (2.3 kB view details)

Uploaded Python 3

File details

Details for the file swiftonpython-0.3.tar.gz.

File metadata

  • Download URL: swiftonpython-0.3.tar.gz
  • Upload date:
  • Size: 2.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.6

File hashes

Hashes for swiftonpython-0.3.tar.gz
Algorithm Hash digest
SHA256 f078c7b17cf74d0b2d054f69d95e0376645354003a9de429021320c6e6645a04
MD5 082de0c96efb72ddb00d4045711d8da3
BLAKE2b-256 452b2905314103d08b1c213255e666072d9ac2376dcb0737188719afe636bff7

See more details on using hashes here.

File details

Details for the file swiftonpython-0.3-py3-none-any.whl.

File metadata

  • Download URL: swiftonpython-0.3-py3-none-any.whl
  • Upload date:
  • Size: 2.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.6

File hashes

Hashes for swiftonpython-0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 f9c1f6c6b71f2f91a32218ee8bde8d1ea4c7334414b1cb9f83415ed7925c3331
MD5 f4b017ca50aa9ae3e3464b2323cd0de8
BLAKE2b-256 6dfdb30a2f223f47eb0379467e0ec44a1476174491f41456d5657afdea392248

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page