linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* original file finding
@ 2024-09-11 10:11 Alex Shi
  2024-09-11 13:29 ` Dongliang Mu
  0 siblings, 1 reply; 7+ messages in thread
From: Alex Shi @ 2024-09-11 10:11 UTC (permalink / raw)
  To: Dongliang Mu, open list:DOCUMENTATION

Hi Dongliang:

In scripts/checktransupdate.py, 
def get_origin_path(file_path):
    paths = file_path.split("/")
    tidx = paths.index("translations")
    opaths = paths[:tidx]
    opaths += paths[tidx + 2 :]
    return "/".join(opaths)

It use a different way instead of the ':Original:' line to find out the origin file.
That may cause file finding failed if we have a different dir map for translation.

Yes, we have no worry since all of them are same. But could we take the ':Original:' usage for a possible dir map changes?

Anyway, just a quick idea.

Thanks
Alex

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: original file finding
  2024-09-11 10:11 original file finding Alex Shi
@ 2024-09-11 13:29 ` Dongliang Mu
  2024-09-12  1:22   ` Alex Shi
  0 siblings, 1 reply; 7+ messages in thread
From: Dongliang Mu @ 2024-09-11 13:29 UTC (permalink / raw)
  To: Alex Shi, Cheng Ziqiu; +Cc: Dongliang Mu, open list:DOCUMENTATION

On Wed, Sep 11, 2024 at 6:11 PM Alex Shi <seakeel@gmail.com> wrote:
>
> Hi Dongliang:
>
> In scripts/checktransupdate.py,
> def get_origin_path(file_path):
>     paths = file_path.split("/")
>     tidx = paths.index("translations")
>     opaths = paths[:tidx]
>     opaths += paths[tidx + 2 :]
>     return "/".join(opaths)

cc +ziqiu

Could you take a look at this function?

>
> It use a different way instead of the ':Original:' line to find out the origin file.
> That may cause file finding failed if we have a different dir map for translation.

Yes, this is more reasonable. BTW, is this enforced in the Chinese or
other language translation?

>
> Yes, we have no worry since all of them are same. But could we take the ':Original:' usage for a possible dir map changes?

Yeah, at least we can take the current method as backup for original
file location.

>
> Anyway, just a quick idea.
>
> Thanks
> Alex
>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: original file finding
  2024-09-11 13:29 ` Dongliang Mu
@ 2024-09-12  1:22   ` Alex Shi
  2024-09-14  1:25     ` Dongliang Mu
  0 siblings, 1 reply; 7+ messages in thread
From: Alex Shi @ 2024-09-12  1:22 UTC (permalink / raw)
  To: Dongliang Mu, Cheng Ziqiu; +Cc: Dongliang Mu, open list:DOCUMENTATION



On 9/11/24 9:29 PM, Dongliang Mu wrote:
> On Wed, Sep 11, 2024 at 6:11 PM Alex Shi <seakeel@gmail.com> wrote:
>>
>> Hi Dongliang:
>>
>> In scripts/checktransupdate.py,
>> def get_origin_path(file_path):
>>     paths = file_path.split("/")
>>     tidx = paths.index("translations")
>>     opaths = paths[:tidx]
>>     opaths += paths[tidx + 2 :]
>>     return "/".join(opaths)
> 
> cc +ziqiu
> 
> Could you take a look at this function?
> 
>>
>> It use a different way instead of the ':Original:' line to find out the origin file.
>> That may cause file finding failed if we have a different dir map for translation.
> 
> Yes, this is more reasonable. BTW, is this enforced in the Chinese or
> other language translation?

It should be used in all language.

> 
>>
>> Yes, we have no worry since all of them are same. But could we take the ':Original:' usage for a possible dir map changes?
> 
> Yeah, at least we can take the current method as backup for original
> file location.

good idea!

> 
>>
>> Anyway, just a quick idea.
>>
>> Thanks
>> Alex
>>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: original file finding
  2024-09-12  1:22   ` Alex Shi
@ 2024-09-14  1:25     ` Dongliang Mu
  2024-09-14 10:38       ` Alex Shi
  0 siblings, 1 reply; 7+ messages in thread
From: Dongliang Mu @ 2024-09-14  1:25 UTC (permalink / raw)
  To: Alex Shi; +Cc: Cheng Ziqiu, Dongliang Mu, open list:DOCUMENTATION

On Thu, Sep 12, 2024 at 9:22 AM Alex Shi <seakeel@gmail.com> wrote:
>
>
>
> On 9/11/24 9:29 PM, Dongliang Mu wrote:
> > On Wed, Sep 11, 2024 at 6:11 PM Alex Shi <seakeel@gmail.com> wrote:
> >>
> >> Hi Dongliang:
> >>
> >> In scripts/checktransupdate.py,
> >> def get_origin_path(file_path):
> >>     paths = file_path.split("/")
> >>     tidx = paths.index("translations")
> >>     opaths = paths[:tidx]
> >>     opaths += paths[tidx + 2 :]
> >>     return "/".join(opaths)
> >
> > cc +ziqiu
> >
> > Could you take a look at this function?
> >
> >>
> >> It use a different way instead of the ':Original:' line to find out the origin file.
> >> That may cause file finding failed if we have a different dir map for translation.
> >
> > Yes, this is more reasonable. BTW, is this enforced in the Chinese or
> > other language translation?
>
> It should be used in all language.

Hi Alex,

Why can't I find this thread in the LKML? We have cc-ed the linux-doc
mailing list.

Jon has different ideas about this origin file finding.

>
> >
> >>
> >> Yes, we have no worry since all of them are same. But could we take the ':Original:' usage for a possible dir map changes?
> >
> > Yeah, at least we can take the current method as backup for original
> > file location.
>
> good idea!
>
> >
> >>
> >> Anyway, just a quick idea.
> >>
> >> Thanks
> >> Alex
> >>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: original file finding
  2024-09-14  1:25     ` Dongliang Mu
@ 2024-09-14 10:38       ` Alex Shi
  2024-09-15 13:20         ` Dongliang Mu
  0 siblings, 1 reply; 7+ messages in thread
From: Alex Shi @ 2024-09-14 10:38 UTC (permalink / raw)
  To: Dongliang Mu; +Cc: Cheng Ziqiu, Dongliang Mu, open list:DOCUMENTATION


On 9/14/24 9:25 AM, Dongliang Mu wrote:
> On Thu, Sep 12, 2024 at 9:22 AM Alex Shi <seakeel@gmail.com> wrote:
>>
>>
>> On 9/11/24 9:29 PM, Dongliang Mu wrote:
>>> On Wed, Sep 11, 2024 at 6:11 PM Alex Shi <seakeel@gmail.com> wrote:
>>>> Hi Dongliang:
>>>>
>>>> In scripts/checktransupdate.py,
>>>> def get_origin_path(file_path):
>>>>     paths = file_path.split("/")
>>>>     tidx = paths.index("translations")
>>>>     opaths = paths[:tidx]
>>>>     opaths += paths[tidx + 2 :]
>>>>     return "/".join(opaths)
>>> cc +ziqiu
>>>
>>> Could you take a look at this function?
>>>
>>>> It use a different way instead of the ':Original:' line to find out the origin file.
>>>> That may cause file finding failed if we have a different dir map for translation.
>>> Yes, this is more reasonable. BTW, is this enforced in the Chinese or
>>> other language translation?
>> It should be used in all language.
> Hi Alex,
>
> Why can't I find this thread in the LKML? We have cc-ed the linux-doc
> mailing list.
>
> Jon has different ideas about this origin file finding.

Hi Dongliang, 

I just copy to linux-doc, not lkml. but Jon could see the thread in linux-doc too. He reply there may just because more people in LKML. :)

As to his and others' comments want to do further check, to confirm if the Original file exists. That further checking make sense too, and could be easy to add, isn't it?


Thanks

Alex

>
>>>> Yes, we have no worry since all of them are same. But could we take the ':Original:' usage for a possible dir map changes?
>>> Yeah, at least we can take the current method as backup for original
>>> file location.
>> good idea!
>>
>>>> Anyway, just a quick idea.
>>>>
>>>> Thanks
>>>> Alex
>>>>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: original file finding
  2024-09-14 10:38       ` Alex Shi
@ 2024-09-15 13:20         ` Dongliang Mu
  2024-09-16 13:20           ` Alex Shi
  0 siblings, 1 reply; 7+ messages in thread
From: Dongliang Mu @ 2024-09-15 13:20 UTC (permalink / raw)
  To: Alex Shi; +Cc: Cheng Ziqiu, Dongliang Mu, open list:DOCUMENTATION

On Sat, Sep 14, 2024 at 6:38 PM Alex Shi <seakeel@gmail.com> wrote:
>
>
> On 9/14/24 9:25 AM, Dongliang Mu wrote:
> > On Thu, Sep 12, 2024 at 9:22 AM Alex Shi <seakeel@gmail.com> wrote:
> >>
> >>
> >> On 9/11/24 9:29 PM, Dongliang Mu wrote:
> >>> On Wed, Sep 11, 2024 at 6:11 PM Alex Shi <seakeel@gmail.com> wrote:
> >>>> Hi Dongliang:
> >>>>
> >>>> In scripts/checktransupdate.py,
> >>>> def get_origin_path(file_path):
> >>>>     paths = file_path.split("/")
> >>>>     tidx = paths.index("translations")
> >>>>     opaths = paths[:tidx]
> >>>>     opaths += paths[tidx + 2 :]
> >>>>     return "/".join(opaths)
> >>> cc +ziqiu
> >>>
> >>> Could you take a look at this function?
> >>>
> >>>> It use a different way instead of the ':Original:' line to find out the origin file.
> >>>> That may cause file finding failed if we have a different dir map for translation.
> >>> Yes, this is more reasonable. BTW, is this enforced in the Chinese or
> >>> other language translation?
> >> It should be used in all language.
> > Hi Alex,
> >
> > Why can't I find this thread in the LKML? We have cc-ed the linux-doc
> > mailing list.
> >
> > Jon has different ideas about this origin file finding.
>
> Hi Dongliang,
>
> I just copy to linux-doc, not lkml. but Jon could see the thread in linux-doc too. He reply there may just because more people in LKML. :)
>
> As to his and others' comments want to do further check, to confirm if the Original file exists. That further checking make sense too, and could be easy to add, isn't it?

+1

@Cheng Ziqiu , can you take care the v2 patch which checks the
existing of original file instead of using original tag?

>
>
> Thanks
>
> Alex
>
> >
> >>>> Yes, we have no worry since all of them are same. But could we take the ':Original:' usage for a possible dir map changes?
> >>> Yeah, at least we can take the current method as backup for original
> >>> file location.
> >> good idea!
> >>
> >>>> Anyway, just a quick idea.
> >>>>
> >>>> Thanks
> >>>> Alex
> >>>>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: original file finding
  2024-09-15 13:20         ` Dongliang Mu
@ 2024-09-16 13:20           ` Alex Shi
  0 siblings, 0 replies; 7+ messages in thread
From: Alex Shi @ 2024-09-16 13:20 UTC (permalink / raw)
  To: Dongliang Mu; +Cc: Cheng Ziqiu, Dongliang Mu, open list:DOCUMENTATION


On 9/15/24 9:20 PM, Dongliang Mu wrote:
> On Sat, Sep 14, 2024 at 6:38 PM Alex Shi <seakeel@gmail.com> wrote:
>>
>> On 9/14/24 9:25 AM, Dongliang Mu wrote:
>>> On Thu, Sep 12, 2024 at 9:22 AM Alex Shi <seakeel@gmail.com> wrote:
>>>>
>>>> On 9/11/24 9:29 PM, Dongliang Mu wrote:
>>>>> On Wed, Sep 11, 2024 at 6:11 PM Alex Shi <seakeel@gmail.com> wrote:
>>>>>> Hi Dongliang:
>>>>>>
>>>>>> In scripts/checktransupdate.py,
>>>>>> def get_origin_path(file_path):
>>>>>>     paths = file_path.split("/")
>>>>>>     tidx = paths.index("translations")
>>>>>>     opaths = paths[:tidx]
>>>>>>     opaths += paths[tidx + 2 :]
>>>>>>     return "/".join(opaths)
>>>>> cc +ziqiu
>>>>>
>>>>> Could you take a look at this function?
>>>>>
>>>>>> It use a different way instead of the ':Original:' line to find out the origin file.
>>>>>> That may cause file finding failed if we have a different dir map for translation.
>>>>> Yes, this is more reasonable. BTW, is this enforced in the Chinese or
>>>>> other language translation?
>>>> It should be used in all language.
>>> Hi Alex,
>>>
>>> Why can't I find this thread in the LKML? We have cc-ed the linux-doc
>>> mailing list.
>>>
>>> Jon has different ideas about this origin file finding.
>> Hi Dongliang,
>>
>> I just copy to linux-doc, not lkml. but Jon could see the thread in linux-doc too. He reply there may just because more people in LKML. :)
>>
>> As to his and others' comments want to do further check, to confirm if the Original file exists. That further checking make sense too, and could be easy to add, isn't it?
> +1
>
> @Cheng Ziqiu , can you take care the v2 patch which checks the
> existing of original file instead of using original tag?


As my understanding, Jon want the ':Original:' file, and next he want to check if the file, which get from tag,  exist ? :)

Thanks

>
>>
>> Thanks
>>
>> Alex
>>
>>>>>> Yes, we have no worry since all of them are same. But could we take the ':Original:' usage for a possible dir map changes?
>>>>> Yeah, at least we can take the current method as backup for original
>>>>> file location.
>>>> good idea!
>>>>
>>>>>> Anyway, just a quick idea.
>>>>>>
>>>>>> Thanks
>>>>>> Alex
>>>>>>

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2024-09-16 13:21 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-11 10:11 original file finding Alex Shi
2024-09-11 13:29 ` Dongliang Mu
2024-09-12  1:22   ` Alex Shi
2024-09-14  1:25     ` Dongliang Mu
2024-09-14 10:38       ` Alex Shi
2024-09-15 13:20         ` Dongliang Mu
2024-09-16 13:20           ` Alex Shi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).