Skip to content

Commit c3b1412

Browse files
authored
Merge pull request #15 from shauryemahajanSF/removeUnwantedFilesFromRepo
W-21280827 | Remove Unwanted Files from CAP
2 parents 0aa8615 + 7a8a021 commit c3b1412

File tree

5 files changed

+101
-3
lines changed

5 files changed

+101
-3
lines changed

.gitignore

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
# ==========================================
2+
# macOS System Files
3+
# ==========================================
4+
.DS_Store
5+
.AppleDouble
6+
.LSOverride
7+
Icon
8+
._*
9+
.DocumentRevisions-V100
10+
.fseventsd
11+
.Spotlight-V100
12+
.TemporaryItems
13+
.Trashes
14+
.VolumeIcon.icns
15+
.com.apple.timemachine.donotpresent
16+
__MACOSX/
17+
18+
# ==========================================
19+
# Windows System Files
20+
# ==========================================
21+
# Windows thumbnails
22+
Thumbs.db
23+
Thumbs.db:encryptable
24+
ehthumbs.db
25+
ehthumbs_vista.db
26+
27+
# Folder config file
28+
Desktop.ini
29+
30+
# Recycle Bin used on separate drives
31+
$RECYCLE.BIN/
32+
33+
# Windows Installer temporary files
34+
*.cab
35+
*.msi
36+
*.msm
37+
*.msp
38+
39+
# ==========================================
40+
# Linux System Files
41+
# ==========================================
42+
# Temporary files (often created by text editors like Vim)
43+
*~
44+
45+
# KDE directory preferences
46+
.directory
47+
48+
# Linux trash folder
49+
.trash
50+
51+
# ==========================================
52+
# General Hidden Files
53+
# ==========================================
54+
# Ignore all hidden files/folders by default
55+
.*
56+
57+
# Keep the .gitignore file itself!
58+
!.gitignore

CONTRIBUTING.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,45 @@ Include the packaged app as a ZIP file with the following naming convention:
2121
avalara-tax-v1.0.0.zip
2222
```
2323

24+
#### How to Generate the ZIP File
25+
26+
When creating your ZIP file, it's important to exclude system files and hidden files that shouldn't be included in the archive. Use the following commands based on your operating system:
27+
28+
##### macOS & Linux (Terminal)
29+
30+
Both macOS and Linux use the `zip` utility. The `-x` flag is your best friend here—it tells the utility to exclude specific patterns.
31+
32+
**The Command:**
33+
```bash
34+
zip -r my_archive.zip folder_to_zip/ -x "*.DS_Store" -x "__MACOSX/*" -x "*/.*" -x "Thumbs.db"
35+
```
36+
37+
**Breakdown of the flags:**
38+
- `-r`: Stands for "recursive." It tells the computer to look inside every subfolder.
39+
- `"*.DS_Store"`: Excludes the macOS folder settings file.
40+
- `"__MACOSX/*"`: Prevents the creation of those annoying resource fork folders.
41+
- `"*/.*"`: The "nuclear option"—this excludes all hidden files (anything starting with a dot).
42+
- `"Thumbs.db"`: Excludes the Windows thumbnail cache.
43+
44+
##### Windows (PowerShell)
45+
46+
Windows doesn't have a native "exclude" flag built into its basic `Compress-Archive` command. To do this cleanly without third-party software, you have to filter the files first and then pipe them into the zip command.
47+
48+
**The Command:**
49+
```powershell
50+
Get-ChildItem -Path ".\folder_name" -Recurse -File | Where-Object {
51+
$_.FullName -notmatch '\\\.DS_Store$' -and
52+
$_.FullName -notmatch '__MACOSX' -and
53+
$_.Name -notmatch '^\.' -and
54+
$_.Name -notmatch 'Thumbs\.db'
55+
} | Compress-Archive -DestinationPath "my_archive.zip"
56+
```
57+
58+
**How this works:**
59+
- `Get-ChildItem`: Grabs every file in your folder.
60+
- `Where-Object`: This acts as a filter. We tell it to only keep files that do not match our "junk" patterns (no .DS_Store, no __MACOSX, no files starting with a dot, and no Thumbs.db).
61+
- `Compress-Archive`: Takes that filtered list and zips it up.
62+
2463
---
2564

2665
### 2. `manifest.json`
-50 KB
Binary file not shown.
22 KB
Binary file not shown.

tax/avalara-tax/manifest.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
{
22
"name": "avalara-tax",
3+
"displayName": "Avalara Tax",
34
"domain": "tax",
45
"description": "Sample Avalara tax app used for testing",
5-
"version": "0.1.3",
6-
"zip": "avalara-tax-v0.1.3.zip",
7-
"sha256": "9cfd3ddd12cbc9f10935735467de61e366068cc5d82beab3c22bc965d7aafc53"
6+
"version": "0.1.4",
7+
"zip": "avalara-tax-v0.1.4.zip",
8+
"sha256": "e7388f82312052991589fea07f7fbdbf6517f40b4ee33a12074f44cc34021c7e"
89
}

0 commit comments

Comments
 (0)