CSS file either deleted or is hidden in atom - html

I have been learning for just over a month now and I started my first project and I was coming to a close with it and literally last sec the CSS file is blank. I am using chrome and atom text editor. I did not have my git acc linked to it so history is not saved on it. The only thing showing on the file for the class is "
1
*
*
*
*
*
"
When I hit backspace it takes forever to delete because I'm pretty sure my code is just hidden there or something. I have no idea what happened. I spent some hours trying to fix it but no dice.

Have you tried opening the file in explorer?
If you right click on your project folder there is an option to open in file explorer. (This may say "Show in file manager" if you're using the latest version of Atom)
Check if the file is there, if it is, try opening it notepad or another simple text editor.
If it's not there it may have been corrupted, I've used atom quite a bit and never encountered this problem.
If it is, you can always just delete the file in your project folder and make a new one, pasting the contents in from when you opened it in notepad.

Related

How can I configure sublime to always open to the same folder?

I have a folder that I want Sublime to always open to ...
my_folder
Is there somewhere I can set this so that when ever I click on the Sublime Icon it opens to this folder?
For some reason if I manually quit sublime text through the menu it will open my last folder on re-opening.
However, if I just click the close X button, it will not ... it will open a blank window.
Is there somewhere I can set this correctly in the JSON file?
Well not sure if you are aware of it, but ST has a quick switch project (usually ctrl+alt+p) that will show you your recently opened projects.
Of course it has its own drawbacks:
Unable to remove one instance from it without removing all (clear recent projects cache)Can’t open the project in a new window… instead it only replaces the current project
But AFAIK this would be the most optimal way to work with multiple projects. you just need to go to the folder of the desired project and open it once and it will be available as recent project in the future…
The point of having to choose where to save the project file, IMO is because you may want to share the same file with other people or just have them wherever you want… maybe having all in one place is good for you (it is for me as well) but other people might like to have it in separate folders. 
I usually work with the project replace window… or just go in “Project -> Open recent -> …” which opens a new ST window for me!
Hope this helps you

Is there a way to open a file in split view from recent files popup

I have this Recent files popup:
I can open any file from it by pressing ENTER. Is there any way to open the file in a split view? I have tab limit set to 1, so opening a file from Recent files and then opening it in a split view replaces the currently open file. I'd like to open a file in a split view without replacing the current tab. Maybe key mapping somehow?
Unfortunately not (as far as my knowledge goes).
https://youtrack.jetbrains.com/issue/IDEA-108556 -- watch this and related tickets (star/vote/comment) to get notified on any progress.
The only other possible options (generally speaking):
Shift + Enter to open it in a new/detached editor.
Open as usual and then use Move Down or Move Right to move it in that split group (will create if you do not have one). But this will NOT work if you set to have only 1 editor tab max.
Open as usual, clone it to bottom/right side (so it opens in both splitters) and then re-open recently closed file in one of the split areas again (yeah .. long and inconvenient).
Move focus to another splitter before invoking Recent Files (if you have no such splitter yet -- create one for current file). Now chose file as usual -- it will replace file in current splitter (inconvenient as you need to think about correct location in advance instead of quickly opening the needed file).

After moving my Windows Store App project I can't compile it because .resw not found

I have a Problem with a Windows Store App.
I moved the folder and now I cant compile it, I get the error:
Fehler 2 File C:\[old path]\Strings\en-US\Resources.resw not found. C:\[new path]\MakePRI
I dont know how to fix it because the app is in the same relative path in the project as before.
any hints for a solution?
This item was probably added to the project with absolute path. You can fix that in one of two ways:
In SolutionExplorer remove Resources.resw from the project. Then click on Show All Files icon to make the file appear in its folder although it's not included in the project (I understand you did copy it over when moving the project). Now right click on the file and select Include In Project. After that you can again turn off Show All Files.
In Solution Explorer right click on the project and select Unload Project. Now right click on the project again and select Edit ProjectName.csproj. In the file find Resources.resw and replace the existing tag (and any subtags) with <PRIResource Include="Strings\en-US\Resources.resw" />. Save the changes and close the file. Right click on the project again and select Reload Project.
I got into this problem and I found an easy solution. Open the project and it will show the error. Now right click on the App name in Solution Explorer (on the right hand side) and select Build.This will set the path again and the project can be run now.

Hard link to a file not working as expected on OS X

I've a file in a folder and I don't know anything about this file (how it's generated and updated) because it comes from an application running on my system of which I don't have the source code.
The file format is clearly json and I successfully created an hard link to it (using the shell command ln file hardLinkToFile) and placed it on another directory.
At this point I check the "2" files and they are exactly the same as expected, but when I perform an action in the application that cause an update of the original file the hard link doesn't get updated.
Any idea on how I can solve this problem?
UPDATE: As pointed out by both Vlad Lazarenko and mvds the file probably get deleted and a new one is created, is there something I can do to obtain a solution equivalent to the hard-link one I thought initially about?
If a hard link is not getting updated, it means that application is removing the old file and creates a new one. Thus, you still have a hard copy of the previous file, but new file has a totally different inode, though path is still the same. You can verify it simply by changing the content of that file yourself - the link should get updated.
I am getting the same behavior in TextEdit, but not in TextMate. I would suspect this is due to the revision control built in to OS X Lions document architecture. TextEdit uses versioning, while TextMate does not. Most likely this function replaces the file instead of changing it, as described by #Vlad Lazarenko.
#Vlad and Francesco. It's really in this way. I verified that vi leaves the inode unchanged and the src and dest file are both changed, while e.g. the kate editor doesn't and I was getting mad to understand why the changes I made in the src file weren't also in the dest file.
You can easily check this with the command ls -li srcfile destfile before editing one of them with each editor I mentioned.
By the way it's not nice that the hard link are application dependent
I guess it is a bit too late...
Anyways, accidentally I found that, if you change the default app for the file, the hard link gets separated from original file. Even if you click on change all and do not relate to that specific file.

How to edit preference file for Notepad++?

My open source project uses spaces, not tabs, in its code.
A contributor to the project has his own website which uses tabs, not spaces.
He uses Notepad++ in Windows to edit files for both projects, and is frustrated when he forgets to manually set the Preferences correctly and thus inserts tabs into my project's files.
Is there a way to edit this Preference via a script? That way he could click one icon to start Notepad++ in mode 1 (running a batch script to modify the Preferences file and then start the program) or click another to start in mode 2.
Or if there's any other way to make him not have to remember this chore, that would work too. Maybe having a Preferences setting that depends on what folder the edited file is inside of?
Any help would be appreciated. Thanks!
The notepad++ setting for replacing tabs with spaces is stored in following xml file
%USERPROFILE%\Application Data\Notepad++\config.xml
The following is the line that needs to be changed
<GUIConfig name="TabSetting" size="4" replaceBySpace="yes" />
Now I don't know how we can edit a file by batch script in windows, but if it is not possible, then he can keep two config files config-tabs.xml and config-spaces.xml. And in the script you can copy appropriate file depending on what he needs to work on.