Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Change way templates are uniquely identified #58
Using names to unique identify templates has never been ideal but I've just stuck with it instead of rethinking. Since this is the full release I'd like to sort this out now, even if it introduces greater risk.
max = 0xfffff min = 0x10000 parts =  parts.push new Date().getTime() parts.push Math.floor(Math.random() * (max - min + 1)) + min parts[i] = part.toString 16 for part, i in parts parts.join('.').toUpperCase()
Which should output something like
added a commit
Jan 30, 2012
I'm happy with the results and I'm going to close this now after fixing some issues surrounding export/import functionality.
However, I feel it's worth mentioning that, if a custom template is imported from a previous version (earlier than 1.0.0) more than once, it will be duplicated as there's no way of knowing it's exactly the same as the old name field is discarded after being imported.