Comments (11)
We could probably remove the clean code but won't writing new files run into the same issue? I haven't heard of any scenarios in which it would be desirable to track the output files before, what is the use case?
from eclipse-typescript.
At least in my case, writing to the file did not create any problem, while failing on the delete would stop the incremental build for any file.
With respect to why tracking generated files it is needed for two reasons:
- our build tool-chain is maven based, and the typescript support for maven is quite reduced (there is an half decent plugin, with a some issues however). Therefore I have to ensure that my build server receives the generated output from source control, as it will not be able to regenerate it outside eclipse (in Jenkins in this case). There several ways in which I could fix, the plugin above, some ant script using tsc from the command line, etc. buy the all bring hassles.
- I'm the only person working with typescript on my team, but the other teammates still need the generated output to the test the app in their environment. If I don't track the generated output, the only other way is to force all of my teammates to install the eclipse plugin (and node!!! By the way, it would be great if node could be in some way directly packaged with the plugin, without requiring a separate download).
from eclipse-typescript.
Ok, I think the best thing to do is probably just remove the clean logic for now then to unblock you.
I'm not sure how we could package up node with the plug-in since it requires different binaries for each platform. I suspect it would greatly increase the size of the download. If you find any info out though, please let me know.
from eclipse-typescript.
If I'm the only one having this type of problems, don't worry about changing the current behavior. I've already put deleting behind a preference in my repo, so I'm not blocked.
You might wan't to try/catch the deleting of resources in any case, just to play it safe.
from eclipse-typescript.
I've always considered the deletion logic a bit suspect so I think it should probably go. The only cleanup we should really be doing is deleting corresponding JavaScript and source map files when a .ts file is deleted (or renamed).
from eclipse-typescript.
It looks like this issue has re-emerged in last versions of the plugin, when using the "Compile all TypeScript files on build" option. This also happens with svn, and it seems limited to full builds.
from eclipse-typescript.
What behavior are you seeing specifically?
from eclipse-typescript.
We have a project with typescript activated, with only the source folder configured (all other paths are empty). We commit every file, both the .ts and the generated .js and .map.js and the workspace is clean.
We then close eclipse and restart it. As soon as eclipse completes rebuilding the project, the generated files are either marked as changed (in case of .git repo), or marked as deleted (in svn repo).
Git seems smarter, 'cos attempting a synchronize afterwards shows no changes. But the svn team provider includes the resources for deletion. Please note that the generated files are there, they are just marked as deleted (and will be deleted if one commits). Changing a source to force the update of the generated ones has the same effect, with the generated file being physically there but marked for delete.
The problem, I believe, depends on the fact that cleaning the project removes the generated files (which would be normal in the general case, but a problem in out setup), and a full build seems to issue a clean and then a compile.
Originally I had patched the plugin to delete the generated files only if the source file was deleted, but we have since then switched to the original plugin to receive the new updates.
Honestly I don't know which could be a good solution satisfying all use cases. Maybe a configuration switch that would avoid cleaning generated resources during a clean (as silly as it might be)?
from eclipse-typescript.
For a full build, I believe that delete and rebuild is the expected behavior, right? Restarting eclipse shouldn't automatically trigger a full rebuild though - is that a workspace option perhaps?
from eclipse-typescript.
Don't think so. We just have the workspace set up with "Build automatically" and I believe that triggers the build (for instance after a svn checkout).
But the problem is unrelated with re-opening eclipse. We can just commit everything, call for a full build without touching any source and we would get the generated files not only marked as modified (which we could live with) but also marked as deleted (with svn), which then generates all types of commit problems.
The problem might be with the svn team provider, that once it detects the file has been deleted it keeps it marked deleted even if regenerated. But I've not found any svn option to change this behavior.
from eclipse-typescript.
Hmm, I'm looking at the code now and I don't see where the compiled JavaScript file would be deleted during normal compilation. They would definitely be deleted during a clean build but that should be it.
from eclipse-typescript.
Related Issues (20)
- NodeJS custom location
- VCLJSTeam.VCLJS Traduzir esta página
- TypeScript 2.1 update break ContentAssist
- support glob in tsconfig
- Missing actual install step in "Installation" section HOT 1
- Use tsconfig option conflict with compiler project specific.
- Error using moduleResolution = 'node' in tsconfig file HOT 1
- tsconfig supports *.js files but fails in plugin HOT 4
- Upgrade to TypeScript 2.1.5 HOT 13
- Can provide options to ignore such errors:Cannot find module 'xxxx' HOT 1
- Installing Typescript Plugin from a JAR file (for air-gapped networks)
- Compiling all workspace when saving a ts file HOT 1
- Settings not availabe HOT 4
- IllegalStateException: The node process has crashed. HOT 2
- Error Occured while Building Workspace for using TypeScript HOT 1
- Cannot add Eclipse TypeScript Plug-in to Eclipse HOT 1
- NullPointerException PresentationReconciler.getDamagedRegion(PresentationReconciler.java:132) HOT 3
- Update Eclipse installation site HOT 2
- Eclipse Plugin Update Site Not Found HOT 3
- eclipse_typescript的更新站点已经无法使用了,请帮忙解决,我们需要新的可用插件下载安装地址
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from eclipse-typescript.