← Back to issue list

`snapcraft clean --destructive` does not delete `.craft` directory

View original Github issue

Metadata

Project
snapcraft
Number
#6001
Type
issue
State
open
Author
steinbro
Labels
Created
2026-01-30 22:25:01+00:00
Updated
2026-01-30 22:33:14+00:00
Closed

Current evaluation

No evaluation has been recorded for this issue yet.

Issue body

### Check existing issues - [x] I've verified that this bug isn't described by any existing issues. ### Bug description After `snapcraft pack` is run in destructive mode, running `snapcraft clean --destructive` removes all expected directories except for `.craft`. ### Steps to reproduce ``` root@snapcraft-test:~# cd `mktemp -d` root@snapcraft-test:/tmp/tmp.9TIyHpcaEM# snapcraft init See https://documentation.ubuntu.com/snapcraft/stable/reference/project-file for reference information about the snapcraft.yaml format. Successfully initialised project. root@snapcraft-test:/tmp/tmp.9TIyHpcaEM# ls -a . .. snap root@snapcraft-test:/tmp/tmp.9TIyHpcaEM# snapcraft pack --destructive Packed my-project_0.1_amd64.snap root@snapcraft-test:/tmp/tmp.9TIyHpcaEM# ls -a . .. .craft my-project_0.1_amd64.snap overlay parts prime snap stage root@snapcraft-test:/tmp/tmp.9TIyHpcaEM# snapcraft clean --destructive root@snapcraft-test:/tmp/tmp.9TIyHpcaEM# ls -a . .. .craft my-project_0.1_amd64.snap snap ``` ### Environment Snapcraft 8.13.2 on Ubuntu 24.04 in an LXD container ### snapcraft.yaml ```yaml ``` ### Log output ```shell ```

Evaluation history

No evaluation history available.