Skip to main content

Share files (UTF-8) through your network. (multi-paltform)

Project description

Pyserved 1.0

Made by Shaurya Pratap Singh

Transfer files from devices the quickest way possible. By Shaurya Pratap Singh 2021 | MIT Licence

Info

This package is used to send files over a network server using sockets. The maximum size of file is 100 mbs.

How does it work?

So this package comes with 2 cli commands pyserved and pyserved-c. The "pyserved" command is for starting up the server which will run on the reciever's server and pyserved-c is for the client to send the file to the server.

Installation

$ pip install pyserved

Guide

So you must have 2 computers to do this , and one sample file to transfer between the computers.

Server

So in 1 computer you must run this command to start the server

$ pyserved

and by executing this command you will get the following results:

$ pyserved
______________________________________________________

You can find out the ip address by typing

 $ ifconfig en1

 or

 $ ifconfig en0

 or you can search google for it.


Server HOST on which you want to run:
PORT:

After filling out the server host and port you will see the following:

$ pyserved
______________________________________________________

You can find out the ip address by typing

 $ ifconfig en1

 or

 $ ifconfig en0

 or you can search google for it.


Server HOST on which you want to run: 192.168.1.20
PORT: 8089
______________________________________________________
[STARTING] SERVER is starting on 192.168.1.20:8089
[RUNNING] Server is succesfully running....
[RUNNING] The files which will be sent to you will be saved on /Users/{user}/pyserved directory.

So when you run this command the server will start the files which will be sent to you will be saved on /Users/{user}/pyserved directory.

Client

While the server is running go on to the another computer and execute order 66 this command:

$ pyserved-c

you will see this:

$ pyserved-c

______________________________________________________

Pyserved CLI Client

Enter the host and port in the fields below.
Server HOST:


So enter the host and port on which the server is running on.

$ pyserved-c
______________________________________________________

Pyserved CLI Client

Enter the host and port in the fields below.
Server HOST: 192.168.1.20
PORT: 8089
Now enter the path of file which you want to send
File path:

Now it is asking for the path of the file which you want to send, so pick up any file which size is lower than 100mb and utf-8 encoded. (like .txt, .json, .py, .md, .ino, ipynb etc.)

$ pyserved-c
______________________________________________________

Pyserved CLI Client

Enter the host and port in the fields below.
Server HOST: 192.168.1.20
PORT: 8089
Now enter the path of file which you want to send
File path:/Users/username/Desktop/opensource/anit/sockets/setup.py

______________________________________________________

So after you enter the filepath go to the computer in which the server is running on and open Finder, go to /Users/username/pyserved, here you will see the copied file,initially with the name "copiedFileXXXX.filetype", if you open it will be the same file!

Update 0.9

Fixed directory creation error.

Licence

This project is licensed under the MIT license.The MIT license gives users express permission to reuse code for any purpose, sometimes even if code is part of proprietary software. As long as users include the original copy of the MIT license in their distribution, they can make any changes or modifications to the code to suit their own needs.

Dont hesitate the make this code better!

© Shaurya Pratap Singh 2021

Huge thanks to my dad for inspiration!

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

pyserved-1.0.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

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

pyserved-1.0-py3-none-any.whl (7.3 kB view details)

Uploaded Python 3

File details

Details for the file pyserved-1.0.tar.gz.

File metadata

  • Download URL: pyserved-1.0.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.6.1 requests/2.24.0 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.5

File hashes

Hashes for pyserved-1.0.tar.gz
Algorithm Hash digest
SHA256 6593988018dbd9f669c3d4b644ca4fe27ba61d0dc30c410a2401829f4ea040ac
MD5 00586a39fb9903ac7a895cb430b458ce
BLAKE2b-256 42e29b69124051919a6bba29968aaabb36811b58ed590eac94e1e31de8a7d301

See more details on using hashes here.

File details

Details for the file pyserved-1.0-py3-none-any.whl.

File metadata

  • Download URL: pyserved-1.0-py3-none-any.whl
  • Upload date:
  • Size: 7.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.6.1 requests/2.24.0 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.5

File hashes

Hashes for pyserved-1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 aa7a2f97757acadc5b00c849f84ecfc845e02af67cd244e7745f2759bb186a5c
MD5 7eda372a397e69ffbfbd79d3d1281820
BLAKE2b-256 27fce75d6be92d6e697f8a219f79439a854ecf4cea48ae55c1111b8e1c25fb0e

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