I would like to provide an installation of Chrome (or probably Chromium?) that comes pre-installed with my extension, installed to a separate folder and has the --enable-experimental-extension-apis turned-on by default. Would also be cool to be able to customize the looks and feels to be more suitable for my brand.
Does anyone know if its allowed by Google's TOS? Is it possible? Was it done before? Is there any easy way to do that, without hacking around on Chromium source code?
If you know enough C to modify some code, mini_installer is a good place to start. This is what people would be downloading anyway, so tweaking some of the code there to suit your needs would be the best bet. Install it where you like, make whatever changes before/after the install, etc.
Otherwise, you could write some kind of script that downloads and runs the installer, and then changes settings. For compatibility with your apparent target audience, a simple batch script would be the best bet.
Another option is Chromium Portable. You make any changes you like, and upload a zip file. All they have to do is download and unzip it. Most users can manage that, but pictures on the download page don't hurt. You could also write a small program or script to download the zip file, unzip it, and run anything that needs to be run (or Chromium it self).
It's technically possible and allowed. Indeed, there are a number of forks of Chromium, such as Iron and Comodo Dragon.
Whether it's a good idea is another question entirely. Unless you're prepared to maintain your fork on a long-term basis (and in particular, to provide software updates to your users on a frequent basis), it's probably not a good idea. You'd probably do better to instruct your users to install Google Chrome normally, then give them a link to install your extension.
As far as experimental extension APIs go, I'd avoid them. They may be removed or changed significantly in future versions of Chrome. If you must use them, just instruct the user on how to enable them.
Related
I've been experimenting with using Chrome DevTools as my primary authoring tool, and am now mostly using them.
As I continue to increase my usage, I'm running into some pain points.
Usually, when I begin working on a project, I now create a dedicated Chrome profile for it. I do this automatically by invoking Chrome with the --user-data-dir flag and storing the browser profile right within the project.
Then I go into the tools, set up my workspace, map my local directories, and so forth. This works great.
What doesn't work so great is that this is a very repetitive process. I'd love to be able to specify the workspace mappings within the project somehow, and then generate the appropriate profile. I'd also love to be able to set other preferences (like indentation, and various other settings on the DevTools "General" page) in a standard way.
I've thought of three ways this might be possible:
There might be an API for this, but I doubt it, as programmatic manipulation of browser preferences obviously is disfavored (but would someone have carved out an exception for DevTools?),
There might be a way to import/export DevTools preferences, and I might be able to generate the import format,
I might be able to figure out where they're stored in the user directory, and manipulate them myself (so far I haven't, though).
There's also one partial solution I've considered:
I might be able to copy a "template" browser profile to get some of the shared settings above. Then I'd still have to do the workspace mapping each time, but I might be able to get away with not doing the rest.
One really elaborate strategy I could try would be to use browser automation, as suggested in Google Chrome - how can i programmatically enable chrome://flags some of the modules from disable mode to enabled mode? ... but that seems like overkill even as I start using the stuff more heavily; I don't think I'm quite ready to invest that kind of up-front effort in it.
Is anyone familiar enough with how the Chrome DevTools preferences work to judge which strategies might be most promising?
There is no way easily sync DevTools settings. They are stored in localstorage scoped to the DevTools. Which means they are in a special sqlite DB which isn't easy to transfer between machines (plus you'd bring all the other stuff with it.)
Sadly, you are left porting this all around by-hand with each new machine.
I want to perform a hack on devtools.js to expand all of the DOM elements by default. I read in another post on here that this was possible.
However, I can't find devtools.js, or for that matter, the Application folder that supposedly exists at C:\Users\Administrator\AppData\Local\Google\Chrome. I've tried this both on my Windows 7 laptop and my Windows XP desktop (different path for the desktop, obviously) and the folder doesn't even exist...which leads me to believe it's somewhere else and named something else. I'm showing hidden folders on both machines, so that's not it, either. I even searched both computers...no devtools.js file on either one.
Where would I look for the devtools.js file?
It appears to be packed in a file called resources.pak. The package seems to contain a lot of other (binary) files as well, so I'm not sure if you're going to have much luck editing it.
Might be a bit late to the party but i was searching for a very comparable question i had and found some answers, so i thought i'd share my findings.
It seems that the devTools.js and also the other files for the DevTools front-end are packaged inside the browser.
So there is no file on your hard-drive named devTools.js, there is an option to get the source for the Developer Tools and use it as a stand alone front-end though.
On this page i found some instructions as to how you would go about using your own front-end.
http://dev.chromium.org/devtools
Good luck!
PM5544
Wanting to take advantage (for the first time) of the open-source nature of open-source software, I want to edit part of Google Chrome. I know exactly which source file to edit, and it's a very small change. However, the entire compressed source distribution tarball is about a gigabyte, and I can't even imagine how painful the recompiling process would be, not to mention how much disk space it would use.
So, the question is: Is there any better way to modify the program than to recompile the entire thing? It seems to be quite a painful thing to do for small changes.
No, there is no other way recompiling Chromium. I recommend you to use the Google Chrome Extensions API if you can. If you want to recompile Google Chrome, the steps are pretty easy, everything is explained in http://dev.chromium.org/developers Some tips (since I am a Chromium contributor)
For a quick start guide: https://docs.google.com/present/view?id=dd9mrt45_0dmtd49c6
Read documentation: http://dev.chromium.org/developers
Make sure you have 10GB of space.
Make sure you have a fast computer (64bit), the more cores/mem the better.
The source code is "not" just 1GB, it is more, after you checkout the sources, you would need to sync your DEPS (thirdparty) via gclient sync That will add another couple of GB.
It will take a lot of time to compile (~1 hour) on modern PCs. If you have a very fast computer, the time of compilation would decrease exponentially.
According to you comments above, you would need to checkout the source at least once, we use Git or SVN for that (read the documentations, we have explained as much as we can on the site). Once you finished compilation, you can always update your source (the same way you update your repository (git pull, gclient sync) Then incremental buildings will be around 5-10 minutes depending what you have changed.
Please follow the documentation (http://dev.chromium.org), I am saying that again because the Chromium community worked hard to make these documentations up-to date, they help new comers get familiar with the project.
Chromium is big, but fun to work with, have fun hacking :)
The open sourced Chromium is not the same thing as Google Chrome. Some specific features (like H264 support) are available in Chrome, but not Chromium. You cannot "build" Chrome; you can build Chromium.
A more feasible approach to make your modification might be to write it as an Extension.
I have an HTML5 site. I want to do following thing:
Walk through files in a folder
Find all images
Get exif file from images
Analyze an exifs (on server)
Correct bad exifs
This is a best scenario, that it can be. I am conscious that 1st and 2second step is possibly done only by selecting this files by user. And 5th step is possible only when the analysis will be done at user's machine. So what is the best way to do it (to get closer as much to the optimal scenario)? What should I use without need to force a user to install anything?
EDIT:
At least I have used free GeckoFX web browser as a basic desktop app. Interface is created in HTML+JS Thx all
You would need to create an application that runs on the computer of the user. You can't create an HTML5 site that does this.
A Chrome HTML5 webapp should be able to do this.
I'm actually looking at this in these days.
Here is a NOT WORKING example ( due to old API specs, I think)
http://benno.id.au/blog/2009/12/30/html5-fileapi-jpegmeta
But should at least give some good insights.
You should use ExifTool.
It is available as a Perl library here:
http://www.sno.phy.queensu.ca/~phil/exiftool/ExifTool.html
And also as a command-line tool which can be ran by the server (same site).
I want to know if i write a Google Chrome extension, will anyone be able to use my code?
It looks like people will be able to see your code. If they can see your code, they can potentially use it.
Windows: C:\Documents and Settings\%USERNAME%\Local Settings\Application Data\Google\Chrome\User Data\Default\Extensions
Linux and Mac:
~/Library/Application Support/Google/Chrome/Default/Extensions/ or
~/.config/google-chrome/Default/Extensions/
The source code is available for inspection/debugging/experimenting & whatever people might want to do. You may try to use a JavaScript obfuscator.
Since Chrome Extensions are written in JavaScript, and everyone can open the Inspector and see the resources for every extension then, yes, everyone can see the source of your extension.
This doesn't mean they'll be able to use it.
If you obfuscate the code or use similar techniques to make the code less readable then you can avoid that others look into how your extension works. But as said, they can still use the Inspector to analyze the extension.
If you must hide the secret algorithm in your extension, then you could use a server back-end to handle the secret stuff, completely avoiding anyone can look at your code.
Although the question has been posted long time ago, and received some answers (none accepted), I am adding my answer to complete previous answers.
Open-source, referring to software, refers to a «source code made available with a license in which the copyright holder provides the rights to study, change and distribute the software to anyone and for any purpose.» (source: Wikipedia)
Unless explicitly stated, software is copyrighted by the author. Even if you have access to sources, without an explicit permission, you can't read it. It's as if you find opened the door of a house; you have the ability to look into it and even walk in. But you don't have any rights to do it, and doing it is likely to put you in trouble.
Everybody can view source code of your extension because it's written in javascript. Nobody has the right to reuse, change and/or distribute your code without your explicit permission.
Moral of the story: never put any sensitive data in your extensions, because it's extremely insecure.
About Open Source, I suggest to read also the Open Source Definition by OSI
Even though Chrome extensions' source code are accessible by the public, it doesn't mean all Chrome extensions are open source. Actually, you don't have the right to copy/reuse/modify their source code either partially or completely, without their authors' permission, except when he/she has announced that it's open source.
Every Chrome Extension gives the user the following rights by default:
5.2 You grant to the user a non-exclusive, worldwide, and perpetual license to perform, display, and use the Products and any content
contained in, accessed by, or transmitted through the Products in
connection with Google Chrome. If you choose, you may include a
separate end user license agreement (EULA) in your Product that will
govern the user’s rights to the Products in lieu of the previous
sentence.
Read the whole agreement here: http://developer.chrome.com/webstore/terms
That doesn't mean that the user has the right to alter and/or distribute your code, but as others have pointed out, they will be able to see your JavaScript if they want to.
I am not sure whether they are open-source or not, but you can easily see the code of any chrome extension.
It is also up to the developers how their code are structured so that whether other can use it by just copy paste or by analyzing the script code.
However, you can also use the Console to analyze the javascript code and use it.
Also, there is a easy and simple in tool in Google Chrome store to view any chrome extension code.
You can download it here (CRX Viewer)
https://chrome.google.com/webstore/detail/chrome-extension-source-v/jifpbeccnghkjeaalbbjmodiffmgedin
Steps to see code using CRX Viewer :
1) Now after installing the Extension, open it and paste the link of the other extension(which you want to see the code).
ScreenShot of the step
2) Now click "Open in this Viewer" and Here we go ....
Generated source code of extension
3) Now you can easily download the code,or view one by one.
Yes they will, it's mandatory open source !