sintaxi/surge — pull request #18 by kennethormandy (2014-11-18 02:16:32+00:00)
Title: Adds basic support for CNAME files

## Basic CNAME support

If you haven’t passed in a domain on the CLI, Surge will pre-fill one from a CNAME file in the project root before suggesting a new one.

To test:

```
echo "example.com" > CNAME
surge
```

### Caveats

- Will only be deployed to the first domain
listed in the CNAME file. Once/if multiple domains are supported on the CLI, this can be change.
- Doesn’t assume it’s a Surge subdomain (ex. If you list `example`, it
will try and deploy to `example`, not `example.surge.sh`. I don’t think
this is a good thing, but didn’t add it yet since it probably requires more eloquently written code to avoid being redundant.)