Skip to content

Commit 010fa68

Browse files
authored
Merge pull request #41 from LayerLens/main
Release 1.0.2
2 parents 061fa67 + fd5537a commit 010fa68

3 files changed

Lines changed: 40 additions & 40 deletions

File tree

.github/workflows/publish-to-aws.yaml

Lines changed: 38 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ jobs:
6666
if [ -f "src/atlas/_version.py" ]; then
6767
echo "Version file found:"
6868
cat src/atlas/_version.py
69-
69+
7070
# Extract version directly
7171
VERSION=$(grep -E '^__version__\s*=' src/atlas/_version.py | grep -o '".*"' | tr -d '"')
7272
echo "Direct extraction result: '$VERSION'"
@@ -81,7 +81,7 @@ jobs:
8181
ls -la ./scripts/get_version.sh
8282
VERSION=$(./scripts/get_version.sh 2>&1)
8383
echo "Script output: '$VERSION'"
84-
84+
8585
# Extract just the version (last line) in case there's debug output
8686
VERSION=$(echo "$VERSION" | tail -n 1)
8787
fi
@@ -104,7 +104,7 @@ jobs:
104104

105105
- name: Create package directory structure
106106
run: |
107-
mkdir -p upload/simple/${{ env.PACKAGE_NAME }}
107+
mkdir -p upload/package/${{ env.PACKAGE_NAME }}
108108
mkdir -p upload/versions/${{ steps.get_version.outputs.VERSION }}
109109
110110
- name: Copy package files to version-specific folder
@@ -170,29 +170,29 @@ jobs:
170170
171171
- name: Download existing versions and prepare directories
172172
run: |
173-
# Copy current version to simple index
174-
cp dist/* upload/simple/${{ env.PACKAGE_NAME }}/
173+
# Copy current version to package index
174+
cp dist/* upload/package/${{ env.PACKAGE_NAME }}/
175175
176-
# Download existing versions from S3 for both simple index and version directories
176+
# Download existing versions from S3 for both package index and version directories
177177
while IFS= read -r version; do
178178
if [ ! -z "$version" ] && [ "$version" != "${{ steps.get_version.outputs.VERSION }}" ]; then
179179
echo "Downloading version $version"
180-
180+
181181
# Create directory for this version
182182
mkdir -p upload/versions/$version
183-
183+
184184
# Download to both locations:
185-
# 1. To simple index (for pip compatibility)
186-
aws s3 sync s3://${{ secrets.S3_BUCKET_NAME }}/versions/$version/ upload/simple/${{ env.PACKAGE_NAME }}/ || echo "Version $version not found in S3"
187-
185+
# 1. To package index (for pip compatibility)
186+
aws s3 sync s3://${{ secrets.S3_BUCKET_NAME }}/versions/$version/ upload/package/${{ env.PACKAGE_NAME }}/ || echo "Version $version not found in S3"
187+
188188
# 2. To version-specific directory (for HTML generation)
189189
aws s3 sync s3://${{ secrets.S3_BUCKET_NAME }}/versions/$version/ upload/versions/$version/ || echo "Version $version not found in S3"
190190
fi
191191
done < all_versions.txt
192192
193193
- name: Generate package index HTML
194194
run: |
195-
cat > upload/simple/${{ env.PACKAGE_NAME }}/index.html << EOF
195+
cat > upload/package/${{ env.PACKAGE_NAME }}/index.html << EOF
196196
<!DOCTYPE html>
197197
<html>
198198
<head>
@@ -203,14 +203,14 @@ jobs:
203203
<p><a href="../../versions.html">View all versions</a></p>
204204
EOF
205205
206-
for file in upload/simple/${{ env.PACKAGE_NAME }}/*.{tar.gz,whl}; do
206+
for file in upload/package/${{ env.PACKAGE_NAME }}/*.{tar.gz,whl}; do
207207
if [ -f "$file" ]; then
208208
filename=$(basename "$file")
209-
echo " <a href=\"$filename\">$filename</a><br/>" >> upload/simple/${{ env.PACKAGE_NAME }}/index.html
209+
echo " <a href=\"$filename\">$filename</a><br/>" >> upload/package/${{ env.PACKAGE_NAME }}/index.html
210210
fi
211211
done
212212
213-
echo "</body></html>" >> upload/simple/${{ env.PACKAGE_NAME }}/index.html
213+
echo "</body></html>" >> upload/package/${{ env.PACKAGE_NAME }}/index.html
214214
215215
- name: Generate versions page HTML
216216
run: |
@@ -231,40 +231,40 @@ jobs:
231231
<body>
232232
<h1>All Versions of ${{ env.PACKAGE_NAME }}</h1>
233233
<p>Available versions of the ${{ env.PACKAGE_NAME }} package.</p>
234-
234+
235235
<div class="install-cmd">
236-
<strong>Install latest:</strong> pip install ${{ env.PACKAGE_NAME }} --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/simple/<br/>
237-
<strong>Install specific version:</strong> pip install ${{ env.PACKAGE_NAME }}==VERSION --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/simple/
236+
<strong>Install latest:</strong> pip install ${{ env.PACKAGE_NAME }} --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/package/<br/>
237+
<strong>Install specific version:</strong> pip install ${{ env.PACKAGE_NAME }}==VERSION --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/package/
238238
</div>
239239
EOF
240240
241241
# Generate version listings
242242
while IFS= read -r version; do
243243
if [ ! -z "$version" ]; then
244244
echo "Processing version: $version"
245-
245+
246246
# Check if this is the current version
247247
CURRENT_CLASS=""
248248
if [ "$version" = "${{ steps.get_version.outputs.VERSION }}" ]; then
249249
CURRENT_CLASS=" current"
250250
fi
251-
251+
252252
cat >> upload/versions.html << EOF
253253
<div class="version$CURRENT_CLASS">
254254
<h3>Version $version</h3>
255255
EOF
256-
256+
257257
if [ "$version" = "${{ steps.get_version.outputs.VERSION }}" ]; then
258258
echo " <p><strong>(Current/Latest Version)</strong></p>" >> upload/versions.html
259259
fi
260-
260+
261261
echo " <div class=\"files\">" >> upload/versions.html
262262
echo " <strong>Available files:</strong><br/>" >> upload/versions.html
263-
263+
264264
# List files for this version
265265
echo "Checking for files in upload/versions/$version/"
266266
ls -la upload/versions/$version/ || echo "Directory not found or empty"
267-
267+
268268
FOUND_FILES=false
269269
for file in upload/versions/$version/*.{tar.gz,whl}; do
270270
if [ -f "$file" ]; then
@@ -274,22 +274,22 @@ jobs:
274274
FOUND_FILES=true
275275
fi
276276
done
277-
277+
278278
if [ "$FOUND_FILES" = false ]; then
279279
echo " <p>No package files found for this version</p>" >> upload/versions.html
280280
echo "Warning: No files found for version $version"
281281
fi
282-
282+
283283
echo " </div>" >> upload/versions.html
284284
echo "</div>" >> upload/versions.html
285285
fi
286286
done < all_versions.txt
287287
288288
echo "</body></html>" >> upload/versions.html
289289
290-
- name: Generate main simple index
290+
- name: Generate main package index
291291
run: |
292-
cat > upload/simple/index.html << EOF
292+
cat > upload/package/index.html << EOF
293293
<!DOCTYPE html>
294294
<html>
295295
<head>
@@ -320,21 +320,21 @@ jobs:
320320
<body>
321321
<h1>LayerLens Python Package Repository</h1>
322322
<p>Custom Python package repository for ${{ env.PACKAGE_NAME }}</p>
323-
323+
324324
<div class="links">
325-
<a href="simple/">Browse packages</a>
325+
<a href="package/">Browse packages</a>
326326
<a href="versions.html">View all versions</a>
327327
</div>
328-
328+
329329
<h2>Installation</h2>
330330
<div class="install-cmd">
331331
# Install latest version<br/>
332-
pip install ${{ env.PACKAGE_NAME }} --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/simple/<br/><br/>
333-
332+
pip install ${{ env.PACKAGE_NAME }} --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/package/<br/><br/>
333+
334334
# Install specific version<br/>
335-
pip install ${{ env.PACKAGE_NAME }}==1.0.0 --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/simple/
335+
pip install ${{ env.PACKAGE_NAME }}==1.0.0 --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/package/
336336
</div>
337-
337+
338338
<h2>Current Version</h2>
339339
<p>Latest version: <strong>${{ steps.get_version.outputs.VERSION }}</strong></p>
340340
</body>
@@ -344,8 +344,8 @@ jobs:
344344
- name: Upload to S3
345345
run: |
346346
# Upload everything except we don't want to delete old versions
347-
# Upload the simple index (with --delete to clean up old files)
348-
aws s3 sync upload/simple/ s3://${{ secrets.S3_BUCKET_NAME }}/simple/ --delete
347+
# Upload the package index (with --delete to clean up old files)
348+
aws s3 sync upload/package/ s3://${{ secrets.S3_BUCKET_NAME }}/package/ --delete
349349
350350
# Upload version-specific files (without --delete to preserve old versions)
351351
aws s3 sync upload/versions/ s3://${{ secrets.S3_BUCKET_NAME }}/versions/
@@ -363,4 +363,4 @@ jobs:
363363
- name: Output installation command
364364
run: |
365365
echo "Package deployed successfully!"
366-
echo "Install with: pip install ${{ env.PACKAGE_NAME }} --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/simple/"
366+
echo "Install with: pip install ${{ env.PACKAGE_NAME }} --index-url https://${{ secrets.CLOUDFRONT_DOMAIN }}/package/"

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "layerlens"
3-
version = "1.0.1"
3+
version = "1.0.2"
44
description = "The official Python library for the LayerLens Atlas API"
55
license = "Apache-2.0"
66
authors = [{ name = "LayerLens", email = "support@layerlens.ai" }]

src/layerlens/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "1.0.1"
1+
__version__ = "1.0.2"

0 commit comments

Comments
 (0)