ashwin271 / ashwin271/treecraft

Files without extensions (Dockerfile, Makefile) are created as directories

Open
#1 0 comments 0 reactions 0 assignees View on GitHub
bug good first issue
Dominant language
Python
Stars
0
Forks
0
PR merge metrics
No merged PRs in 30d

Description

## Description
When trying to create a project structure that includes files like Dockerfile or Makefile, treecraft creates them as directories instead of files. This happens because the code only checks for file extensions to determine if something should be a file.

### Steps to Reproduce
1. Create a tree structure file with:
```
project/
├── Dockerfile
└── src/
└── Makefile
```
2. Run treecraft with this file
Check the output - Dockerfile and Makefile are created as directories

### Expected Behavior
Files like Dockerfile, Makefile, LICENSE, etc. should be created as files, not directories.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the treecraft behavior with the shown project structure, then locate the logic that decides whether a path is a file based on its extension. Verify the handling of Dockerfile, Makefile, and LICENSE, and consider the work complete when those extensionless names are created as files while directory paths remain directories.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.