Commit graph

1493 commits

Author SHA1 Message Date
James Allen
9e5c98dd07 Use local references to variable 2018-02-01 16:52:43 +00:00
Shane Kilkelly
19c97cb15b Merge pull request #289 from sharelatex/afc-track-edit-sessions
Send editing session heartbeat to the analytics service
2018-02-01 12:31:38 +00:00
Brian Gough
5e52ade1ff Merge pull request #286 from sharelatex/bg-prevent-duplicate-filenames
prevent duplicate filenames
2018-01-31 11:50:45 +00:00
James Allen
9a9938083c Merge pull request #267 from sharelatex/as-remove-rollout
Remove rollout logic for auto compile and link sharing
2018-01-31 10:27:09 +00:00
James Allen
aa6c16593e Add renamingToName override name for instant apparent renames 2018-01-31 09:42:41 +00:00
James Allen
9721dffbb6 Add missing state reset to error handler 2018-01-31 09:41:58 +00:00
Brian Gough
1c6dc66ed1 prevent double calls to rename 2018-01-29 16:45:59 +00:00
Brian Gough
6ed181d52c fix check for name in filetree move 2018-01-29 15:27:52 +00:00
Brian Gough
63fa024d98 client-side duplicate check for move/rename/create 2018-01-29 15:24:51 +00:00
Brian Gough
8e239e0c64 only update client filetree on success 2018-01-25 17:09:31 +00:00
Alberto Fernández Capel
839ea496f1 Track clicks anywhere on the window as activity when the editor is open 2018-01-25 16:32:00 +00:00
Alberto Fernández Capel
a68489a604 Track session activvity if the user scrolls the editor 2018-01-25 16:10:47 +00:00
Alberto Fernández Capel
7d0d18ea5e Use the cursor:editor:update event to track user activity
It is strictly a superset of the change event we were using
before: if there's a change, there will be always a cursor
update, but there can be cursor updates (like when the user
presses the arrow keys) that don't change the document.

This is coherent with what we do to track user activity at

dfb9943521/public/coffee/ide/connection/ConnectionManager.coffee (L49-L50)
2018-01-24 17:20:30 +00:00
Alberto Fernández Capel
8a1523cc03 Read project id from the global window var 2018-01-23 15:58:59 +00:00
Nate Stemen
ea5063d7ea dont return needsClosingBrace from Helpers 2018-01-23 09:35:24 -05:00
Nate Stemen
91302cfb16 move end bracket logic to helpers and remove unecessary unpacking 2018-01-23 09:35:24 -05:00
Nate Stemen
30eca714eb fix random things with snippets 2018-01-23 09:35:24 -05:00
Nate Stemen
d2adc753aa use helpers to see if there is '}' already 2018-01-23 09:35:24 -05:00
Alberto Fernández Capel
0bef5531bb Rename editSession -> editingSession 2018-01-23 10:29:11 +00:00
Alberto Fernández Capel
868e32c1bc Send edit sessions heartbeat to the analytics service 2018-01-22 15:10:52 +00:00
Alasdair Smith
4d29c4d769 Remove unused link sharing onboarding now at 100% 2018-01-17 15:18:40 +00:00
Alasdair Smith
45de9bb5dc Remove unused autocompile rollout logic now that at 100% 2018-01-17 15:17:55 +00:00
James Allen
6d04eeaa03 Merge pull request #256 from sharelatex/ja-display-v2-history-users
Inject v2 user details into project-history updates and diffs
2018-01-15 14:21:14 +00:00
James Allen
662122bb1c CI and local dev environment improvements
The need for this became very noticeable due to the slowness of filesystem access in docker-in-mac, with a full compile taking over a minute for me in docker. Using make to introduce incremental compile makes this near instantaneous outside of docker (if only a few files have changed), and quick enough inside docker.

With incremental compile via make, it compiles quickly enough that re-compiling and restarting the web service automatically when backend files change is quick enough now. This is how the service is run via docker-compose in https://github.com/sharelatex/sharelatex-dev-environment, so it shouldn't be necessary to manually restart the container each time a coffee file changes.

At the moment Jenkins pull web modules in via the GitSCM plugin, but I believe this is creating a dependency in Jenkins, where any commits to any of the modules causes all of the web branches to rebuild. By doing it via our own scripts we can hopefully avoid this. It also creates a build process which is reproducible locally.

**Note that at the moment in this PR all modules pull from `ja-dockerize-dev` branches, but these should be merged first, and this PR updated to point to the master branches before merging**. This is necessary for other changes to build process/docker-compose workflow.

As well as a Makefile for web, there is now a `Makefile.module`. This is copied into each module directory by the top-level Makefile, and is written in a way to be flexible and support unit tests, acceptance tests, front-end js for the ide and main, and the modules `app/coffee` directory, while allowing modules to have some of these missing (not all modules have e.g. acceptance tests, or front-end JS). This will allows us to refine the build process in future, without needing to update the Makefile in each module repo separately (I found this to be a painful part of this development).

This makes web compatible with the docker-compose workflow at https://github.com/sharelatex/sharelatex-dev-environment, where each service is running in its own docker container, with networking managed by docker.

Previously the Makefile was set up to run unit tests in docker with `make unit_tests`. This now just runs them natively. In the CI, they are run in docker anyway (all steps in Jenkins are), and locally, they run fine natively with `npm run test:unit`, or can be run in docker via https://github.com/sharelatex/sharelatex-dev-environment with `bin/run web_sl npm run test:unit`.

Previously we did a lot of juggling with only mounting source files (coffee, less, etc) into the docker container for acceptance tests. This was to avoid creating root owned files if the whole directory was mounted. Now instead the whole web directory is mounted read-only, with the compilation step done outside of the container before running the tests.

This allows the host and container to share the `node_modules` folder as well, which avoids needing to `npm install` twice on the CI box, and should speed up the build by a few minutes.

On macOS, this would cause a problem with compiled modules if you tried to use the same `node_modules` to run the app natively. However, if running via docker-compose in https://github.com/sharelatex/sharelatex-dev-environment, this is no longer a problem.
2018-01-15 09:36:41 +00:00
James Allen
17a5dfa5a5 Inject v2 user details into project-history updates and diffs 2018-01-11 11:32:16 +00:00
James Allen
79055d0e8d Merge pull request #243 from sharelatex/ja-dont-show-binary-diffs
Show apology message instead of raw binary files
2018-01-11 08:42:13 +00:00
Nate Stemen
c43aa54bee Merge branch 'ns-fix-package-command-meta' 2018-01-08 08:53:42 -05:00
Nate Stemen
7af615ff6c Merge branch 'ns-no-duplicate-packages' 2018-01-08 08:53:07 -05:00
Nate Stemen
cf4d6c1165 Merge branch 'master' into ns-no-duplicate-packages 2018-01-05 11:46:44 -05:00
James Allen
692182c784 Show apology message instead of raw binary files 2018-01-04 10:53:49 +00:00
Nate Stemen
d2ee03d9b9 make commandNames object for fast lookups 2017-12-21 15:51:50 -05:00
James Allen
940b22ef95 Remove debug line 2017-12-20 16:42:09 +00:00
James Allen
d0fee7e76c Show a file tree of changed paths, so we can work with renamed and deleted files 2017-12-20 16:22:32 +00:00
Paulo Reis
0a0c6c6c0c Merge branch 'master' into pr-style-v2-chatpane 2017-12-20 09:50:49 +00:00
James Allen
1d89a535a1 Merge pull request #208 from sharelatex/ja-front-end-history
Add in web front end that supports v2 history; Fixes #168
2017-12-19 15:00:34 +00:00
James Allen
b4a5e5a041 Tidy up HistoryV2Manager 2017-12-19 13:58:47 +00:00
James Allen
8a3fadbfc1 Style the edit/add/rename options 2017-12-19 13:58:47 +00:00
James Allen
50b12e88a2 Add HistoryV2Manager alongside existing HistoryManager 2017-12-19 13:58:47 +00:00
James Allen
8ea779af58 Add some front end tests for HistoryManager 2017-12-19 13:58:47 +00:00
James Allen
4691a6e85c Get diffs showing in client 2017-12-19 13:58:47 +00:00
James Allen
a1615e6d84 Prototype of requesting history information by doc path, while tracking renames 2017-12-19 13:58:47 +00:00
Brian Gough
388a052647 Merge pull request #213 from sharelatex/bg-allow-autocompile-without-code-check
allow autocompile without code check
2017-12-19 13:46:12 +00:00
Nate Stemen
685595ed0a remove comment 2017-12-19 08:44:19 -05:00
Paulo Reis
88d669cbb5 Remove debugging statements. 2017-12-19 10:52:17 +00:00
Alasdair Smith
f3342f327d Merge pull request #202 from sharelatex/as-v2-upgrade-redirect
Use V1 trial page on V2 instead of legacy SL
2017-12-19 10:07:08 +00:00
Nate Stemen
7d5c661b4e make command names local array 2017-12-15 11:10:44 -05:00
Brian Gough
8d91cd2748 allow autocompile without code check 2017-12-14 16:19:43 +00:00
Henry Oswald
cbf656518f remove versioned files from fingerprinting 2017-12-14 11:24:47 +00:00
Paulo Reis
c03ce6fdf7 Configure chat messages colors per brand. 2017-12-14 11:24:05 +00:00
Paulo Reis
ca68f01a9d Build chat message styles on the controller side (allowing for extra parameters). 2017-12-14 11:23:22 +00:00
Alasdair Smith
b7a43d95e0 Remove unused method, now handled by FreeTrialModalController 2017-12-13 15:55:32 +00:00
Alasdair Smith
e7992e65e4 Merge branch 'master' into as-v2-upgrade-redirect 2017-12-13 14:45:51 +00:00
Alasdair Smith
4c81cd874f Remove unnecessary method - handled by FreeTrialModalController 2017-12-13 11:09:46 +00:00
Nate Stemen
618f04ea7a allow package manager to have access to metadata 2017-12-12 15:14:24 -05:00
Nate Stemen
68b57f8d95 check current commands against package commands 2017-12-12 14:33:11 -05:00
Paulo Reis
59e675797e Merge branch 'master' into pr-style-v2-resizers 2017-12-11 15:55:50 +00:00
Paulo Reis
0652fc62a0 Configure resizer cursors for v2. 2017-12-11 15:33:00 +00:00
James Allen
69499847e4 Refactor front end code into validateCaptcha service 2017-12-11 12:32:43 +00:00
James Allen
83086e4a79 Add recaptch to share endpoint 2017-12-11 11:57:59 +00:00
Nate Stemen
9bf5d1e14c removing labels service 2017-12-05 13:57:36 -05:00
Paulo Reis
9fda8e62fa Merge branch 'pr-style-v2-resizers' of github.com:sharelatex/web-sharelatex-internal into pr-style-v2-resizers 2017-12-04 13:48:52 +00:00
Paulo Reis
fd852004fe Refactor synctex controls z-index handling. 2017-12-04 12:25:40 +00:00
James Allen
158b0d56cf Merge branch 'master' into pr-style-v2-resizers 2017-12-04 10:01:45 +00:00
Paulo Reis
826f49b9a4 Add default resizer values to layout directive. 2017-11-30 15:24:39 +00:00
Nate Stemen
c2bb8b9f89 removing calls 2017-11-29 13:30:53 -05:00
Nate Stemen
74ba7402de Merge branch 'ns-file-completer' 2017-11-29 09:20:09 -05:00
Nate Stemen
26df9bca05 Merge pull request #136 from sharelatex/ns-autocomplete-bugs
fixing popup and code folding issues
2017-11-28 10:28:54 -05:00
Nate Stemen
2a50a18d23 Merge branch 'ns-package-aware-autocomplete' 2017-11-28 10:24:37 -05:00
Nate Stemen
8ef48925c1 Merge pull request #71 from sharelatex/ns-package-completer
fixing package completer
2017-11-28 08:56:49 -05:00
Alasdair Smith
e61b82c452 Remove unused link sharing rollout, but keep onboarding popup 2017-11-22 17:07:50 +00:00
Alasdair Smith
6f8b0c6e87 Revert "Remove old unused link sharing onboarding"
This reverts commit 66a0a7ff8b5b5081d86df333429cb0455221c81a.
2017-11-22 16:46:16 +00:00
Nate Stemen
ac9e27713d changing allowed file types 2017-11-22 11:25:02 -05:00
Alasdair Smith
de3b9d6a49 Remove old unused link sharing onboarding 2017-11-22 16:09:32 +00:00
Alasdair Smith
f85880ba38 Remove old unused track changes notice 2017-11-22 15:03:46 +00:00
Alasdair Smith
8f32f0d65f Remove old unused track changes onboarding 2017-11-22 14:48:22 +00:00
Brian Gough
69cb93fe64 Merge pull request #139 from sharelatex/bg-fix-spelling-cancel-request
fix the cancellation of spelling requests
2017-11-22 09:45:36 +00:00
Brian Gough
dc71a6a0a1 Merge pull request #113 from sharelatex/bg-prevent-editing-in-broken-ace-session
put ace in readonly mode when changing session
2017-11-22 09:45:19 +00:00
Nate Stemen
2f03bb6015 adding file completer 2017-11-21 11:26:44 -05:00
Alasdair Smith
1a8a915116 Merge pull request #77 from sharelatex/ns-autocomplete-insertion-bug
fix autocomplete insertion on single backslash; Fixes #55
2017-11-20 15:20:45 +00:00
Alasdair Smith
3c0c670b5f Merge pull request #78 from sharelatex/ns-capital-letter-autocomplete-bug
allow for capital letters in commands; Fixes #56
2017-11-20 15:20:18 +00:00
Brian Gough
029e3b1557 fix the cancellation of spelling requests 2017-11-20 12:25:09 +00:00
Nate Stemen
f00dbf3d56 fixing popup and code folding issues 2017-11-17 16:25:45 -05:00
Alasdair Smith
154943ba68 Don't check for linting errors if code check is disabled
There are a couple of reasons for this:

1. Some linting errors are returned from the server after a compile is run,
replacing client-side linting errors. If code check is disabled this does not
happen, and therefore linting errors persist until the next compile. This makes
it appear as though autocompile is not running

2. It is likely that if code check is disabled, the user is deliberately
ignoring linting errors and therefore the linting check is pointless
2017-11-17 16:38:44 +00:00
Nate Stemen
00e3e8da9f adding last labels configuration 2017-11-16 14:59:04 -05:00
Nate Stemen
c78a0ae209 removing comment 2017-11-16 14:49:29 -05:00
Nate Stemen
c051316aac adding deleted file 2017-11-16 14:45:20 -05:00
Brian Gough
bd09ef81f2 added comments 2017-11-16 15:41:16 +00:00
Brian Gough
dc6110db8d put ace in readonly mode when changing session
if the session fails to attach successfully (e.g due to an exception in
the changeSession event handler) the editor will be left in a state
where the user will not be able to enter any text.  This should at least
cause them to reload the editor.
2017-11-16 11:32:08 +00:00
Brian Gough
125a5ec606 temporarily avoid exception in ace event handler
full fix will be to use the angular $http cancellation mechanism
2017-11-15 16:28:31 +00:00
Nate Stemen
a78330877b fixing services call 2017-11-15 10:14:31 -05:00
Nate Stemen
428ae3aa53 adding labels service back 2017-11-15 09:27:46 -05:00
Shane Kilkelly
aea8e77f8a Merge branch 'as-fix-rollout-2' 2017-11-13 09:50:46 +00:00
Shane Kilkelly
8ba9073606 Merge branch 'sk-link-sharing-onboarding' 2017-11-13 09:31:44 +00:00
Brian Gough
fe12a341e1 Merge pull request #89 from sharelatex/bg-slow-connection-fix
increase allowed op backlog and flush tolerance
2017-11-13 09:22:18 +00:00
Shane Kilkelly
42c0974671 Place the linksharing popover from the right, not the left.
This ensures the popover reflows properly with window resize.
2017-11-10 12:05:12 +00:00
Shane Kilkelly
666ee0669a Alter position of link-sharing popover, and better image 2017-11-10 10:24:36 +00:00
Shane Kilkelly
44420b41d6 Remove stray console log 2017-11-09 15:13:58 +00:00
Shane Kilkelly
766c8d6f0f Add a general 'ide:loaded' event, to init popover 2017-11-09 15:12:55 +00:00
Shane Kilkelly
470ad36218 Add onboarding popup for link-sharing 2017-11-09 14:28:11 +00:00
Alasdair Smith
8174a849a1 Reset to new analytics key 2017-11-08 11:01:36 +00:00