Full Code of meterup/awdl_wifi_scripts for AI

main 92b311662e9b cached
8 files
3.9 KB
1.3k tokens
1 requests
Download .txt
Repository: meterup/awdl_wifi_scripts
Branch: main
Commit: 92b311662e9b
Files: 8
Total size: 3.9 KB

Directory structure:
gitextract_bqhd4pi6/

├── LICENSE
├── README.md
├── awdl-daemon.sh
├── awdl.sh
├── cleanup-and-reenable-awdl.sh
├── com.meter.wifi.awdl.plist
├── disable_awdl.sh
└── disable_disable_awdl.sh

================================================
FILE CONTENTS
================================================

================================================
FILE: LICENSE
================================================
MIT License

Copyright (c) 2022 Meter, Inc.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.


================================================
FILE: README.md
================================================
See https://www.meter.com/mac-osx-awdl-psa for more context. This script will disable AWDL (Apple Wireless Direct Link)
in order to improve WiFi connectivity for Apple M1/M2 MacBooks.

# Usage

## Run it one time

1. On your Mac, open the Terminal app.
2. Run: 
```bash <(curl -sL https://www.meter.com/awdl.sh)```
3. Acknowledge the prompt and type in your admin password.


## Run it automatically after a restart. 

1. On your Mac, open the Terminal app.
2. Run: 
```curl -sL https://www.meter.com/awdl-daemon.sh | bash```

## Remove the scripts and renable awdl0 interface
```
curl -s https://raw.githubusercontent.com/meterup/awdl_wifi_scripts/main/cleanup-and-reenable-awdl.sh | bash &> /dev/null
``` 


================================================
FILE: awdl-daemon.sh
================================================
#!/bin/bash

curl -s https://raw.githubusercontent.com/meterup/awdl_wifi_scripts/main/disable_awdl.sh > ~/disable_awdl.sh
sudo chmod u+x ~/disable_awdl.sh
cd /Library/LaunchDaemons/ && sudo curl -sO https://raw.githubusercontent.com/meterup/awdl_wifi_scripts/main/com.meter.wifi.awdl.plist
sudo sed -i -- "s/YOUR_USERNAME/${USER}/g" /Library/LaunchDaemons/com.meter.wifi.awdl.plist
sudo launchctl unload -w /Library/LaunchDaemons/com.meter.wifi.awdl.plist 2> /dev/null
sudo launchctl load -w /Library/LaunchDaemons/com.meter.wifi.awdl.plist


================================================
FILE: awdl.sh
================================================
#!/usr/bin/env bash

read -p "See https://www.meter.com/mac-osx-awdl-psa for more details. You will be prompted for your admin password. Do you want to continue? y/n" choice

case $choice in
[yY]* ) sudo echo "Installing disable_awdl.sh in your tmp directory. This will run in the background." ;;
[nN]* ) exit ;;
*) exit ;;
esac

curl -s https://raw.githubusercontent.com/meterup/awdl_wifi_scripts/main/disable_awdl.sh > /tmp/disable_awdl.sh
chmod u+x /tmp/disable_awdl.sh

sudo bash /tmp/disable_awdl.sh > /dev/null &


================================================
FILE: cleanup-and-reenable-awdl.sh
================================================
#!/bin/bash

sudo launchctl unload -w /Library/LaunchDaemons/com.meter.wifi.awdl.plist
sudo rm /Library/LaunchDaemons/com.meter.wifi.awdl.plist*
sudo pkill -f /tmp/disable_awdl.sh
sudo pkill -f ~/disable_awdl.sh
sudo rm /tmp/disable_awdl.sh
rm ~/disable_awdl.sh
sudo ifconfig awdl0 up


================================================
FILE: com.meter.wifi.awdl.plist
================================================
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>Label</key>
	<string>com.meter.wifi.awdl</string>
	<key>ProgramArguments</key>
	<array>
		<string>/Users/YOUR_USERNAME/disable_awdl.sh</string>
	</array>
	<key>RunAtLoad</key>
	<true/>
</dict>
</plist>


================================================
FILE: disable_awdl.sh
================================================
#!/usr/bin/env bash

set -euo pipefail

while true; do
    if ifconfig awdl0 |grep -q "<UP"; then
        (set -x; ifconfig awdl0 down)
    fi

    sleep 1
done

================================================
FILE: disable_disable_awdl.sh
================================================
#!/usr/bin/env bash

set -euo pipefail

read -p "See https://www.meter.com/mac-osx-awdl-psa for more details. You will be prompted for your admin password. Do you want to continue? y/n: " choice

case $choice in
[yY]* ) sudo echo "Stopping disable_awdl.sh from running in the background." ;;
[nN]* ) exit ;;
*) exit ;;
esac

sudo pkill -f /tmp/disable_awdl.sh
sudo ifconfig awdl0 up
Download .txt
gitextract_bqhd4pi6/

├── LICENSE
├── README.md
├── awdl-daemon.sh
├── awdl.sh
├── cleanup-and-reenable-awdl.sh
├── com.meter.wifi.awdl.plist
├── disable_awdl.sh
└── disable_disable_awdl.sh
Condensed preview — 8 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (5K chars).
[
  {
    "path": "LICENSE",
    "chars": 1068,
    "preview": "MIT License\n\nCopyright (c) 2022 Meter, Inc.\n\nPermission is hereby granted, free of charge, to any person obtaining a cop"
  },
  {
    "path": "README.md",
    "chars": 708,
    "preview": "See https://www.meter.com/mac-osx-awdl-psa for more context. This script will disable AWDL (Apple Wireless Direct Link)\n"
  },
  {
    "path": "awdl-daemon.sh",
    "chars": 541,
    "preview": "#!/bin/bash\n\ncurl -s https://raw.githubusercontent.com/meterup/awdl_wifi_scripts/main/disable_awdl.sh > ~/disable_awdl.s"
  },
  {
    "path": "awdl.sh",
    "chars": 519,
    "preview": "#!/usr/bin/env bash\n\nread -p \"See https://www.meter.com/mac-osx-awdl-psa for more details. You will be prompted for your"
  },
  {
    "path": "cleanup-and-reenable-awdl.sh",
    "chars": 285,
    "preview": "#!/bin/bash\n\nsudo launchctl unload -w /Library/LaunchDaemons/com.meter.wifi.awdl.plist\nsudo rm /Library/LaunchDaemons/co"
  },
  {
    "path": "com.meter.wifi.awdl.plist",
    "chars": 379,
    "preview": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE plist PUBLIC \"-//Apple//DTD PLIST 1.0//EN\" \"http://www.apple.com/DTDs/P"
  },
  {
    "path": "disable_awdl.sh",
    "chars": 160,
    "preview": "#!/usr/bin/env bash\n\nset -euo pipefail\n\nwhile true; do\n    if ifconfig awdl0 |grep -q \"<UP\"; then\n        (set -x; ifcon"
  },
  {
    "path": "disable_disable_awdl.sh",
    "chars": 383,
    "preview": "#!/usr/bin/env bash\n\nset -euo pipefail\n\nread -p \"See https://www.meter.com/mac-osx-awdl-psa for more details. You will b"
  }
]

About this extraction

This page contains the full source code of the meterup/awdl_wifi_scripts GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 8 files (3.9 KB), approximately 1.3k tokens. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!