2
头图

original link

What should the ultimate LAN transmission experience be like?

only needs one step, double-click the software to start sharing, no deployment, no configuration, close to zero learning cost

  • Open the folder to share
  • Double-click to share (to start sharing, just double-click to run)
  • Send sharing link to friends
  • Small partners download the required files through the link
  • close sharing

why it

  • Simple:

    • No installation, single file, double-click to run the program to share, no deployment, no configuration
    • The program is less than 100k, can be downloaded at any time and run at any time
  • fast

    • Based on local area network transmission, no external network broadband is used, and no traffic is consumed
    • Point-to-point direct transmission, no need to upload and then download
  • Safety

    • Based on local area network transmission, without any intermediaries, data will not be stored in any third party, preventing information leakage

Windows side instructions

  • download LAN
  • Put the "Sharer" in the folder you want to share. If you want to share the files on the desktop, you can put the "Sharer" on the desktop.
  • Double click "Sharer"

  • Right-click "Sharer", click to open the sharing page, and open the folder page you are sharing in the browser

  • Copy the link and send it to your friends, who will get the same page when they visit the link
  • Click the link on the page to download the file. If it is a media file, the browser will open the preview function, you can ctrl + s to save the file
  • principle:

    • Since I am not familiar with Windows development, this is the easiest tool I can find on the Windows side.
    • The author information of the tool was not found, so I can only say thank you silently.

Instructions for use on mac

  • Click download the LAN and get the "Sharer" file

  • Put the "Sharer" in the folder you want to share. If you want to share the files on the desktop, you can put the "Sharer" on the desktop.
  • Double click to run "Sharer"

  • "Sharer" will automatically open the folder page you are sharing in the browser
  • Copy the link and send it to your friends, who will get the same page when they visit the link
  • Click the link on the page to download the file. If it is a media file, the browser will open the preview function, you can ctrl + s to save the file
  • The transmission speed of the local area network is relatively fast, which can reach 3m/s under normal circumstances, realizing the fast transmission of large files.

  • Principle: This is a simple python script, the command SimpleHTTPServer to quickly build a server with python. The mac system has built-in python, which does not need to be installed in advance, so there is no pre-environmental requirement.

    #!/usr/bin/env python
    # -*- coding: utf-8 -*-
    import webbrowser
    import socket
    import random
    import sys
    import os
    
    # 获取本机 ip
    try:
      s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
      s.connect(('8.8.8.8', 80))
      ip = s.getsockname()[0]
    finally:
      s.close()
    print(ip)
    
    # 使用随机端口
    randomPort = random.randint(20000, 30000)
    # 使用默认浏览器,打开分享的页面
    webbrowser.open('http://' + ip + ':' + str(randomPort))
    # 打开要分享的目标文件夹
    os.chdir(sys.path[0])
    # 启动服务,建设静态文件服务
    os.system('python -m SimpleHTTPServer ' + str(randomPort))

If you encounter execute permission problems on the mac side

  • If the mac side prompts that you do not have permission to execute the software, you need to grant permission, but the authorization process only needs to be performed once, and subsequent use does not require re-authorization.
  • Open the "Terminal" software that comes with the mac

  • Enter chmod +x , drag the software into the terminal, and automatically obtain the path of the software.
  • Enter to complete the authorization

The pursuit of minimalism, the pursuit of extreme


momo707577045
2.4k 声望603 粉丝

[链接]