form attached JS attributes I'm trying to convert this:

&lt;script type="text/javascript" data-main="/Scripts/submenu/main" src="/Scripts/require.js"&gt;&lt;/script&gt;


into something like this: 

$form['#attached']['js'] = array(
        libraries_get_path('lib').'/Scripts/require.js' =&gt; array(
            '#attributes' =&gt; array('data-main' =&gt; 'main'),
        ),
);


but I can't seem to find the way to add an attribute :(
Any Ideas?
From what I remember, drupal_add_js, which ultimately is called, doesn't support attributes in the script element. You can use drupal_add_html_head to add js with other attributes; the docs page has some examples on how to do this.