Home Download Buy Blog Forum Support

Different Build systems, based on the file location

Different Build systems, based on the file location

Postby thetrompf on Wed Aug 29, 2012 7:56 pm

Hi.

I am trying to create a project file, which takes care of different build systems, based on file types and location.

But the case is, that both my client and server is coded in coffee script, so "select": "source.coffee" isn't sufficient, so I was wondering

if it is possible to make something like this:
Code: Select all
{
   "name": "coffee-client",
   "cmd": ["${project_path}/scripts/build.sh", "client"],
   "working_dir": "${project_path}/scripts",
   "shell": true,
   "selector": "${project_path}/client/scripts/(soruce.coffee|source.js)"
},
{
   "name": "coffee-server",
   "cmd": ["${project_path}/scripts/build.sh", "server"],
   "working_dir": "${project_path}/scripts",
   "shell": true,
   "selector": "${project_path}/server/src/(soruce.coffee)"
}


Great editor though, keep up the good work.

// Happy developer/user.
thetrompf
 
Posts: 3
Joined: Wed Aug 29, 2012 7:49 pm

Re: Different Build systems, based on the file location

Postby thetrompf on Thu Aug 30, 2012 7:20 am

Anyone?
thetrompf
 
Posts: 3
Joined: Wed Aug 29, 2012 7:49 pm

Re: Different Build systems, based on the file location

Postby bizoo on Thu Aug 30, 2012 8:15 am

No it's not possible.

You can create 2 different project and specify which Build System you want:
http://www.sublimetext.com/docs/2/projects.html

I don't think it's possible to do what you want with a custom Build target (http://docs.sublimetext.info/en/latest/reference/build_systems.html).

However, it look possible to do you own plugin that change the current Build system based on the path before running the build command.
bizoo
 
Posts: 873
Joined: Wed Dec 08, 2010 6:53 am
Location: Switzerland

Re: Different Build systems, based on the file location

Postby thetrompf on Sat Sep 01, 2012 2:09 pm

Thanks will try that, and report back the result.
thetrompf
 
Posts: 3
Joined: Wed Aug 29, 2012 7:49 pm


Return to Technical Support

Who is online

Users browsing this forum: shagabutdinov and 13 guests