How to programmatically set the color scheme for a theme? Is there a way to programmatically change the color scheme, set by the color module, for a certain theme in Drupal 6 (in PHP or using drush)? For example, I can change Garland's color scheme from the UI:


but I want to do it programatically.
No - this is not possible in 6.x due to how color is intended to work. Its meant to be a simple way to change a very basic theme, not for advanced users. In 6.x, when you change your color settings, it is doing the following:


Replaces hexidecimal colour values in CSS files 
Creates sliced images with the new colours for use as CSS background images  
Copies unchanged images without alterations


This creates a dump of 'color files' that looks like this in your files directory (for the Garland theme)

bg-bar-white.png
bg-bar.png
bg-content-left.png
bg-content-right.png
...
style.css


It also creates a random number for the folder each time, so the folder is getting deleted and recreated each time you save the changes. 

All of this is to make it easier for novice users to change their colors, with I assume the understanding that if users could configure their own CSS and theme in code, they wouldn't be using the color module to begin with. This approach is also confirmed here on D.O by Jeff Burnz


  Currently there is no way in Drupal core to export your custom color
  scheme to file, i.e. no way to capture the configuration


Conversely, there is no way to import an existing dump of colors files into your site.