Little cleanup is doc and descriptors

This commit is contained in:
Mathieu Carbou
2024-06-14 10:58:45 +02:00
parent b70d36f2be
commit 4cba41098d
8 changed files with 28 additions and 17 deletions

View File

@@ -47,10 +47,12 @@ jobs:
- name: Install core
run: arduino-cli core install --additional-urls "${{ matrix.index_url }}" ${{ matrix.core }}
- name: Install AsyncTCP-esphome
- name: Install AsyncTCP (ESP32)
if: ${{ matrix.core == 'esp32:esp32' }}
run: ARDUINO_LIBRARY_ENABLE_UNSAFE_INSTALL=true arduino-cli lib install --git-url https://github.com/mathieucarbou/AsyncTCP#v3.1.4
- name: Install ESPAsyncTCP-esphome
- name: Install ESPAsyncTCP (ESP8266)
if: ${{ matrix.core == 'esp8266:esp8266' }}
run: ARDUINO_LIBRARY_ENABLE_UNSAFE_INSTALL=true arduino-cli lib install --git-url https://github.com/mathieucarbou/esphome-ESPAsyncTCP#v2.0.0
- name: Build CaptivePortal

View File

@@ -4,7 +4,7 @@
[![Continuous Integration](https://github.com/mathieucarbou/ESPAsyncWebServer/actions/workflows/ci.yml/badge.svg)](https://github.com/mathieucarbou/ESPAsyncWebServer/actions/workflows/ci.yml)
[![PlatformIO Registry](https://badges.registry.platformio.org/packages/mathieucarbou/library/ESP%20Async%20WebServer.svg)](https://registry.platformio.org/libraries/mathieucarbou/ESP%20Async%20WebServer)
Asynchronous HTTP and WebSocket Server Library for ESP32.
Asynchronous HTTP and WebSocket Server Library for ESP32, ESP8266
Supports: WebSocket, SSE, Authentication, Arduino Json 7, File Upload, Static File serving, URL Rewrite, URL Redirect, etc.
This fork is based on [yubox-node-org/ESPAsyncWebServer](https://github.com/yubox-node-org/ESPAsyncWebServer) and includes all the concurrency fixes.

View File

@@ -1,7 +1,7 @@
# bundle exec jekyll serve --host=0.0.0.0
title: ESP Async WebServer
description: "Asynchronous HTTP and WebSocket Server Library for ESP32"
description: "Asynchronous HTTP and WebSocket Server Library for ESP32, ESP8266"
remote_theme: pages-themes/cayman@v0.2.0
plugins:
- jekyll-remote-theme

View File

@@ -4,7 +4,7 @@
[![Continuous Integration](https://github.com/mathieucarbou/ESPAsyncWebServer/actions/workflows/ci.yml/badge.svg)](https://github.com/mathieucarbou/ESPAsyncWebServer/actions/workflows/ci.yml)
[![PlatformIO Registry](https://badges.registry.platformio.org/packages/mathieucarbou/library/ESP%20Async%20WebServer.svg)](https://registry.platformio.org/libraries/mathieucarbou/ESP%20Async%20WebServer)
Asynchronous HTTP and WebSocket Server Library for ESP32.
Asynchronous HTTP and WebSocket Server Library for ESP32, ESP8266
Supports: WebSocket, SSE, Authentication, Arduino Json 7, File Upload, Static File serving, URL Rewrite, URL Redirect, etc.
This fork is based on [yubox-node-org/ESPAsyncWebServer](https://github.com/yubox-node-org/ESPAsyncWebServer) and includes all the concurrency fixes.

View File

@@ -1,7 +1,7 @@
{
"name": "ESP Async WebServer",
"version": "2.10.8",
"description": "Asynchronous HTTP and WebSocket Server Library for ESP32. Supports: WebSocket, SSE, Authentication, Arduino Json 7, File Upload, Static File serving, URL Rewrite, URL Redirect, etc.",
"description": "Asynchronous HTTP and WebSocket Server Library for ESP32, ESP8266. Supports: WebSocket, SSE, Authentication, Arduino Json 7, File Upload, Static File serving, URL Rewrite, URL Redirect, etc.",
"keywords": "http,async,websocket,webserver",
"homepage": "https://github.com/mathieucarbou/ESPAsyncWebServer",
"repository": {

View File

@@ -2,7 +2,7 @@ name=ESP Async WebServer
version=2.10.8
author=Me-No-Dev
maintainer=Mathieu Carbou <mathieu.carbou@gmail.com>
sentence=Asynchronous HTTP and WebSocket Server Library for ESP32
sentence=Asynchronous HTTP and WebSocket Server Library for ESP32, ESP8266
paragraph=Supports: WebSocket, SSE, Authentication, Arduino Json 7, File Upload, Static File serving, URL Rewrite, URL Redirect, etc
category=Other
url=https://github.com/mathieucarbou/ESPAsyncWebServer

View File

@@ -4,31 +4,31 @@ build_flags =
-Wall -Wextra
-D CONFIG_ARDUHAL_LOG_COLORS
-D CORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_VERBOSE
lib_deps =
bblanchon/ArduinoJson @ 7.0.4
mathieucarbou/Async TCP @ ^3.1.4
; https://github.com/mathieucarbou/AsyncTCP
; https://github.com/me-no-dev/AsyncTCP
esphome/ESPAsyncTCP-esphome @ 2.0.0
upload_protocol = esptool
monitor_speed = 115200
monitor_filters = esp32_exception_decoder, log2file
[platformio]
lib_dir = .
src_dir = examples/CaptivePortal
; src_dir = examples/CaptivePortal
; src_dir = examples/SimpleServer
; src_dir = examples/StreamFiles
src_dir = examples/StreamFiles
; src_dir = examples/Filters
; src_dir = examples/Draft
[env:arduino]
platform = espressif32
board = esp32dev
lib_deps =
bblanchon/ArduinoJson @ 7.0.4
mathieucarbou/Async TCP @ ^3.1.4
[env:arduino-2]
platform = espressif32@6.7.0
board = esp32dev
lib_deps =
bblanchon/ArduinoJson @ 7.0.4
mathieucarbou/Async TCP @ ^3.1.4
[env:arduino-3]
platform = espressif32
@@ -36,6 +36,9 @@ platform_packages=
platformio/framework-arduinoespressif32 @ https://github.com/espressif/arduino-esp32.git#3.0.1
platformio/framework-arduinoespressif32-libs @ https://github.com/espressif/arduino-esp32/releases/download/3.0.1/esp32-arduino-libs-3.0.1.zip
board = esp32dev
lib_deps =
bblanchon/ArduinoJson @ 7.0.4
mathieucarbou/Async TCP @ ^3.1.4
[env:esp8266]
platform = espressif8266

View File

@@ -206,8 +206,14 @@ void AsyncStaticWebHandler::handleRequest(AsyncWebServerRequest *request)
if (request->_tempFile == true) {
time_t lw = request->_tempFile.getLastWrite(); // get last file mod time (if supported by FS)
if (lw) setLastModified(gmtime(&lw));
String etag(lw ? lw : request->_tempFile.size()); // set etag to lastmod timestamp if available, otherwise to size
// set etag to lastmod timestamp if available, otherwise to size
String etag;
if (lw) {
setLastModified(gmtime(&lw));
etag = String(lw);
} else {
etag = String(request->_tempFile.size());
}
if (_last_modified.length() && _last_modified == request->header(F("If-Modified-Since"))) {
request->_tempFile.close();
request->send(304); // Not modified