![]() |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
@pichlo
I've enabled user auto-accept for translations teams, so just become a translator of your language and translate it :) |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
All transaltions for available patches done in Danish
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
I translated most of your patches to Polish language.
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Thanks to all translators!!! But I still need your help!!!
Analog clock patch doesn't have these translations: * Chinese Hong Kong * Norwegian * Portuguese * Slovak Custom operator text patch doesn't have these translations: * Chinese Simple * Chinese Hong Kong * Finnish * Italian * Norwegian * Portuguese * Slovak Devicelock faith-text patch doesn't have these translations: * Chinese Simple * Chinese Hong Kong * Finnish * Italian * Norwegian * Portuguese * Slovak Remorse timeout settings patch doesn't have these translations: * Chinese Hong Kong * Finnish * French (unfinished) * Italian * Norwegian * Portuguese * Slovak Zoom settings patch doesn't have these translations: * Chinese Hong Kong * Finnish * French * Italian * Norwegian * Portuguese * Slovak Voicecall combined patch doesn't have these translations: * Chinese Simple * Chinese Hong Kong * Finnish * French * German * Italian * Norwegian * Portuguese * Slovak Zoom settings patch doesn't have these translations: * Chinese Hong Kong * Finnish * French * Italian * Norwegian * Portuguese * Slovak |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
I am sorry, I promised you a translation and even requested a language but now that I got it, I am finding it difficult to get a couple of hours straight during the holiday period. The kids suck out all my energy ;) I will get to it as soon as normality returns in the new year.
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
French should be ok, I'm not comfortable with the Remorse timeouts patch translation, I did what I think fits the best possible.
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
btw: no remark ;) |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
@romu me too :D |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
I thought so but it might have been a copy/paste mistake by myself. BUT I detected that immediately and am sure I edited my post to remove that :confused: Hmm, but now I did :) |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
'Force large covers' and 'Always show close icon' is actually such a good combo! I'm so glad, SF2s ui paradigm feels much more logical to me this way, along with nonpaged launcher and 'quick settings on power menu'. Now top edge swipe open toggles while closing apps is still enough acessible without additional tap&hold, long tap kinda irritates me anyway.
Also, pointless and not pretty 'handle' of the launcher is easily hideable, which finetunes the ui experience. I just renamed the png-s. |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Hi guys, Happy New Year and all the crappola!,:rolleyes:
Question; I've made a patch for bigger system fonts throughout the UI. I have changed the fonts manually to get the desired effect, but an actual patch would be good - certainly for those of us with not-so-good eyesight. τΏτ I realise this 'idea/app' may not appeal to many of you young whipper-snappers with near 20/20 vision, but I'm in my mid 40's and 'thangs ain't what they used to be'! My problem; My patch installs, it shows in patchmanager, but it just won't apply..? - I'm pretty certain it is my unified_diff.patch file that contains the problem - this is mainly because I'm not fully sure what I'm doing. I really have made hundreds of adjustments but still cannot get the patch to actually apply. I have used the command 'diff' on 2 files to get the patch data, but how do I successfully 'diff' between 2 folders, especially when those 2 folders sit among 4 others. No matter how I do it, my results do not work - my head is starting to hurt! :confused: Now, rather than telling me to "GO AND LEARN LINUX/QML/SFOS-SDK", could someone take me under their wing and guide me through what is left of making this patch work - I'd really appreciate the help!, by the way, I am learning about all the aspects of this wonderful OS, but my study time is limited and sometimes a nudge in the right direction is all that's required and not a bunch of cryptic answers that confuse me even more :) If anyone is willing to help, that would be great, upon someone offering their help, I'll upload the relevant files. Regards, |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
copy all files you want to edit to one folder?
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
Thanks coderus, not quite one folder, but a .rar file containing my RPM for patch and files I want to add. Also contains .txt file from me with what I'd like to achieve. Hope it makes sense to you - my head hurts! Dropbox download; https://www.dropbox.com/s/teyb67xhvq...fonts.rar?dl=0 |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
I mean copy all original files to one folder, make changes, and then make diff for all files in folder to single patch. open it and fix paths to files inside patch to actual locations.
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
Sorry for confusion, still a bit hungover here. Have a laugh at the patch I made, you know you want to! ;) Regards, |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
best way is to have actual tree inside folder (c:\bla-bla\patches\my-super-patch\source\usr
c:\bla-bla\patches\my-super-patch\source\usr\share etc.) and use git in commandline or any tool, init folder and commit original files, and then you only need to produce git diff to file and output will be your final patch you can test in patchmanager directly. |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
I'll try the method you describe in your previous post. I'm not familiar with 'git' and I don't fully understand (yet) what your describing here. What is 'git diff'? - my brother is a git with a difference, but I'm sure that won't help me! ;) Thanks for info, I'll let you know how I get on, I'm sure I will have more questions. I've eaten, so it's now time to get busy 'diffing' ;) |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
It took me a while to type this and coderus has beaten me but since I spent so much effort typing it I will post it anyway even though it probably does not tell you anything new.
I second coderus' suggestion to copy the whole tree. Regarding git diff, there are other options. Some visual diff utilities (sadly, most of them for Windows) can compare whole directories but only to the point of showing you which files have changed. You still have to descend to each file if you want to see the line by line differences and/or produce a diff file. I would say the easiest and most obvious solution for you would be to find which files have changed and then diff them one by one, concatenating the diffs in a single unified_diff.patch file. Have a look at some other patches that modify more than one file to see what unified_diff.patch looks like in such situations. For example, Remorse Items Timeout controls or Return old pulley menu. |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
I now cannot find or recall which diff command I had used before, silly me hasn't kept notes on it. What is the best command for diff, rather which options and output type - I see some output as a .txt file, while some output with .patch - what's best? |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
What's difficult?... Save original file as filename.ext.orig, modify filename.ext and make diff
cd /path_to_filename diff -u filename.ext.orig filename.ext > unified_diff.patch ext = extension, qml, f.e. |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Right, so far, here's what I've got and I haven't yet tried to create patch with this output - it doesn't look right, it certainly does not look like any other patch file I've seen so far.
Any thoughts?, just try it I suppose and fail for the umpteenth time I guess....... root@Jolla fonts]# diff -U0 /usr/share/fonts/roboto /usr/share/patchmanager/patches/sailfishos-bigger-system-fonts/sailfishos-bigger-system-fonts/usr/share/fonts/roboto Only in /usr/share/fonts/roboto: Roboto-Light.ttf Only in /usr/share/patchmanager/patches/sailfishos-bigger-system-fonts/sailfishos-bigger-system-fonts/usr/share/fonts/roboto: Roboto-Medium.ttf Only in /usr/share/patchmanager/patches/sailfishos-bigger-system-fonts/sailfishos-bigger-system-fonts/usr/share/fonts/roboto: Roboto-Regular.ttf Only in /usr/share/fonts/roboto: Roboto-Thin.ttf [root@Jolla fonts]# diff -U0 /usr/share/fonts/sail-sans-pro /usr/share/patchmanager/patches/sailfishos-bigger-system-fonts/sailfishos-bigger-system-fonts/usr/share/fonts/fira-sans-pro Only in /usr/share/patchmanager/patches/sailfishos-bigger-system-fonts/sailfishos-bigger-system-fonts/usr/share/fonts/fira-sans-pro: FiraSans-Bold.ttf Only in /usr/share/patchmanager/patches/sailfishos-bigger-system-fonts/sailfishos-bigger-system-fonts/usr/share/fonts/fira-sans-pro: FiraSans-Heavy.ttf Only in /usr/share/fonts/sail-sans-pro: SailSansPro-ExtraLight.ttf Only in /usr/share/fonts/sail-sans-pro: SailSansPro-Light.ttf Not what I expected, where's all the +++ and the --- and wotnot? (I guess that's more about files not folders).....help! :) |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
I'm struggling Ancelad, simple as that, I don't fully get what I'm doing, my fingers are bleeding and my keyboard is drowning in blood!........ Save original file?, what file?, can you guys answer in laymans terms, I'm not a coder, I;m a Windows monkey of 20 years!, skilled in clicking coloured icons!, I don't know Linux!, coding, diffing etc........I'm getting there though, mm by mm. |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Markkyboy watch this: http://www.youtube.com/watch?v=39fOlkHPk98
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
I can't explain what does 'original' means... Original = original, not modified, without changes... Original file is original in Windows such as in Linux...
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Ok, let's do it step by step...
1) Login into putty and winscp 2) Go to destination folder, for example, /usr/share/fonts Code:
cd /usr/share/fontsCode:
cp Sans.ttf Sans.ttf.orig5) Run Code:
diff -u Sans.ttf.orig Sans.ttf > unified_diff.patch6) Open unified_diff.patch and you will see something like this: Code:
--- Sans.ttf.origCode:
--- /usr/share/fonts/Sans.ttf |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
You do see that I'm diffing on folders not files and the files are font files and so are not editable. So far, I have succeeded in generating empty unified_diff.patches and others containing nothing relating to any other type of patch file I've seen so far. I don't know what I'm doing wrong. I need to clean up my file system, there are unwanted files all over now, boy, what a mess and it only serves to confuse me more. This is harder than I thought. Files seem easier to diff compared to folders. I will keep trying, thanks for your input. It makes the most sense so far and is familiar to what little I've already learned. |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
OK. Step one, make a copy of all the files you are going to change. Then, when dealing with whole directories, you have to get the list of altered files. Write them down in whatever form you find most comfortable: quill on papyrus if necessary. Then go down the list and for each file, compare the changed file with the backup copy, using Ancelad's instructions. Only use >> ("append to the end") instead of > ("overwrite from the beginning"), since your patch file will contain concatenated differences from multiple files.
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Right, despite clear instructions from Ancelad, I'm still unable to produce a working patch.
At Pichlo's suggestion, I put together the diff output into a unified_diff.patch file, compiled the RPM and installed it on my device. It installs, it shows in patchmanager but still will not apply. I have no idea where I'm going wrong. I'd really like to achieve making this with or without help. Here's my final diff output, bearing in mind this is 'hand-made' as it was constructed from 2 different outputs. This is my last attempt tonight, my head hurts!......, Code:
--- /usr/share/fonts/roboto |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
It is now crystal clear that we were talking about the goat whilst you were talking about the cart. It is also possible that you might be trying to push Patchmanager beyond its limits. Perhaps it would help if you first tried to explain what you wanted to achieve. By the looks of it, you are trying to replace one file with another. This is not what unified_diff.patch is for: it is for replacing the files content of a text file. For example, you have a file containing this text: Code:
Now is the timeCode:
Now is the timeCode:
--- /original/file/nameA unified diff can contain lists of differences for multiple files, all following a similar format. Have you done some background reading and/or checked any existing patches as I suggested? In your case, /usr/share/fonts/roboto is a directory, not a file. A unified diff cannot work. Perhaps you meant something like: Code:
--- /usr/share/fonts/roboto/Roboto-Light.ttf |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Thanks for your detailed reply, much of which I'm now beginning to grasp, which should put me in good stead for making other patches. I found many examples like yours, along the way.
My 'idea'; bigger systems fonts throughout the UI (already installed files manually on my device, looks pretty good to me). I'm trying to create an RPM so I can install different font files (into /usr/share/fonts) for better readability in the general UI I want to remove the 'sail-sans-pro' folder and its 2 font files (a+b) and replace with a 'fira-sans-pro' folder and its new font files (a+b). Then, I would like to change the 2 font files (a+b) existing in the 'roboto' font folder for new font files (a+b). That's it. Obviously it needs to uninstall cleanly and leave or restore the original font files. I also do understand now that, diff tool is for files as you say, not folders, this is quite apparent through my hundreds of attempts at getting the right output from 'diffing' folders. (barking and tree, springs to mind) Hope that's clear enough. Also, here's what I had made so far (RPM) and relevant files, except working unified_diff.patch (which may now be irrelevant); https://www.dropbox.com/s/teyb67xhvq...fonts.rar?dl=0 ...oO(Now, where's my quill sharpener gone?)Oo... |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
OK. Your case sounds like a job for a plain old RPM, without involving Patchmanager at all. Unless it also involves altering some QML files, but you did not mention that.
Basically, all you have to do is drop a few files in their respective locations and remove some existing files. The new files will be part of your installation package, removing existing files would go in you pre- or post-install script. No patching necessary. To allow for a clean uninstallation, you will have to make a backup of the files you have removed. The simplest way of making a backup is to simply rename the files, preferably to something unique to avoid conflicts with other packages. The simplest way of renaming is to change the extension, e.g. ttf -> bak, but a safer way could be something like Roboto-Light.ttf -> Roboto-Light.ttf.Markkyboys-super-duper-cool-patch.backup. Your unistall script will then rename it back. I am typing this on my Jolla in McDonalds while keeping an eye on the kids to keep them out of too much mischief so cannot devote more time to you but I will have a look at your code as soon as I can. Probably later tonight. Of course, someone can beat me to it by then ;) |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Thanks again Pichlo, especially while engaging in family time, much appreciated.
Sorry my description was a bit loose, I was hungover and shouldn't have been at the keyboard, I really tied myself in knots, but thanks to you, I now see why I wasn't succeeding where patching is concerned. Yep, you're right and I see it now, a plain old RPM with a script for the hiding/renaming existing font files. I have yet to have a go at scripting, I'll look for some examples. I realised around 3am this morning, that I can just install my new fonts to the existing sail-sans-pro folder and then hide/rename (as you've said) the existing .ttf files by placing a period at the beginning of the title. Same for the files in the 'roboto' folder, add new fonts and then hide/rename the existing fonts. Thanks again Pichlo, look forward to your response, as and when :) Regards, |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Hello Ancelad,
I was trying to help you with tha translation and I could send one. Then I noticed, that it did not accepted. Got some rejection notification via email.. Can I help you to translate or not? :D Or did I do something wrong? |
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Quote:
|
Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
Hey Markkyboy, sorry about the delay. Family life, a horrible thing ;) (No, not really but the truth is I have never enough time for anything.)
I have checked out your code and had a few questions which I tried settling via a PM but apparently you opted out of PMs so I have to post here. Here it goes... Am I reading it right that all you need for your patch to work is replacing some font files? Don't you need to update some manifest file or something? How will the OS know it should use your new files and not throw an error about the missing ones? If the answer is yes, that's all you need to do, then you do not need to involve Patchmanager at all. Your .spec file will have only these sections: %files Pretty much as it is, only without the second line (referring patchmanager). You do not remove the files listed here in your %postun section; the uninstallation will automatically delete all files listed here. %pre Here you backup the existing font files. The simplest way is renaming the whole roboto and sail-sans-pro directories to something safe that you can rename back on unistallation. %postun This section will run after the unistallation, i.e. after all your new files and/or directories have been deleted. Now is the time to rename your backup back to their original names. Here is something I concocted quickly without testing. It will almost certainly not work straight away and will need your tweaking, but it should at least give you the basic idea. It will also need some adopting for different code paths for fresh install and upgrade, or you may simply disallow upgrades and force an upgrade through uninstall and fresh install. Code:
Name: sailfishos-patch-bigger-system-fontsSince Patchmanager is no longer involved, this has become off-topic in this thread. I am happy to take it offline or move it to another thread. |
| All times are GMT. The time now is 03:53. |
vBulletin® Version 3.8.8