mirror of
https://github.com/morten-olsen/parcel.git
synced 2026-02-08 01:36:24 +01:00
20 lines
342 B
TypeScript
20 lines
342 B
TypeScript
class Config {
|
|
get repo() {
|
|
if (!process.env.GITHUB_REPOSITORY) {
|
|
return 'morten-olsen/foobar';
|
|
}
|
|
return process.env.GITHUB_REPOSITORY;
|
|
}
|
|
|
|
get user() {
|
|
const [user] = this.repo.split('/');
|
|
return user;
|
|
}
|
|
|
|
get isProd() {
|
|
return process.env.NODE_ENV === 'production';
|
|
}
|
|
}
|
|
|
|
export default new Config();
|